-
Began Watching Optimising array creation
Hi all, In PHP just wondering if anyone knows whether one method of creating multiple indexes within an array is more efficient / preferable to another? ` $listing['one'] = $x; … -
Replied To a Post in Optimising array creation
Hi James, I think your second listing should actually be coded:- $listing = [ 'one' => $x, 'two' => $y, 'three' => $z ]; -
Began Watching Php multi array
Hi all, I am aiming to create an array with the same structure as this: Array ( [798D25C0DEABD] => Array ( [quantity] => 1 ) [40B2B0FA3D222] => Array ( [quantity] … -
Replied To a Post in Php multi array
Hi, Try not to use for loops to iterate an array. I'm not sure what you are trying to achieve, but i've constructed similar data and looped through it. Hope … -
Replied To a Post in php array string issue
Just noticed the inner $key should be $key2 -
Began Watching php array string issue
Hi all, I have a fairly limited understanding of how objects work exactly, but basically I have: `$response[] = $html->data->identifier;` Which I would think stored the values as an array, … -
Replied To a Post in php array string issue
Hi James, $response[] = will create (if it doesn't exist) or append the right-hand value to the $response array. So if $html->data->identifier is a simple string, e.g. 'Price', then a … -
Replied To a Post in ul / li menu made from database.. How to make one stay selected
Hi diafol, I think that is a personal preference. I myself prefer to use the alternative PHP syntax and simply output PHP variables inline. -
Began Watching ul / li menu made from database.. How to make one stay selected
Hello Guys.... Im a first year student in web coding. Im making my exam project right now and i really need you guys help for this simple thing :D. In … -
Replied To a Post in ul / li menu made from database.. How to make one stay selected
<style>.selected {background: yellow}</style> <?php $menu[] = array('menu_id' => 1, 'menu_text' => 'Home'); $menu[] = array('menu_id' => 2, 'menu_text' => 'Service'); $menu[] = array('menu_id' => 3, 'menu_text' => 'About Us'); $menu[] … -
Replied To a Post in Can't retrieve Ajax Request
Hi, Sorry for the delay in replying. Can you describe in a non-technical way what it is that you are wanting to achieve? -
Replied To a Post in Can't retrieve Ajax Request
This type of id? <img id="457" src="image.png"> -
Began Watching Can't retrieve Ajax Request
Hi all, I'm not too familiar with Ajax but I believe I grasp the basics. So I'm sending an id which I retrieve from an element to a php page … -
Replied To a Post in Can't retrieve Ajax Request
What is part ? is it a string of html or a numeric ? -
Replied To a Post in Change code to jQuery and now value is not being displayed
I've created a small piece of code based on yours, but without the frills, for you to review. http://jsfiddle.net/z04bpvky/1/ -
Began Watching Change code to jQuery and now value is not being displayed
Hi guys, I change my code from Javascript to jQuery and I believe I have everything allright, but my jQuery is not showing the value. Can you help me with … -
Replied To a Post in Change code to jQuery and now value is not being displayed
Hi, .val() is for form values. you need to use .text()
The End.