anchor with image |
[eluser]TWP Marketing[/eluser]
[EDIT] in the time it took to write this, you have several other replies, so this may be irrelevant... [quote author="pierpads" date="1326913594"]Hello to everyone! I've got a problem with an anchor containing an image: echo anchor('controllerPrivato/visualizzaPagina',img($banner_image)); where $banner_image contains the src and the id of the image. The problem is: I need that when someone clicks on the image, it redirects on a specific page with a certain id_page (I have a separated variable for that id_page). How can I append the page_id to this anchor? (controllerPrivato/visualizzaPagina) waits for a $_POST variable, is that possible to pass it such a variable by the anchor?? thank you very much for help. [/quote] First, please use the [ code][/ code] tags when posting code, it is easier to read. You will find information about the img() helper here: http://ellislab.com/codeigniter/user-gui...r.html#img You may add the id_page parameter to the url string in the anchor() helper: Code: ... You may then read the $_POST data, perhaps using the uri class library to read the segments: http://ellislab.com/codeigniter/user-gui...s/uri.html For instance: Code: ... |
Messages In This Thread |
anchor with image - by El Forum - 01-18-2012, 12:06 PM
anchor with image - by El Forum - 01-18-2012, 01:16 PM
anchor with image - by El Forum - 01-18-2012, 01:20 PM
anchor with image - by El Forum - 01-18-2012, 01:22 PM
anchor with image - by El Forum - 01-18-2012, 01:24 PM
anchor with image - by El Forum - 01-18-2012, 01:24 PM
anchor with image - by El Forum - 01-18-2012, 01:25 PM
anchor with image - by El Forum - 01-18-2012, 01:31 PM
anchor with image - by El Forum - 01-18-2012, 01:37 PM
|