Post by cart builder » Fri Apr 18, 2014 11:16 pm

Hi all,

I've created a delivery icon in the footer and I would like some help please to do the following:

Make the image clickable so that it directs to the Delivery Information page.

('Delivery Information' link is already in the footer which I would like to keep).

Any help would be greatly appreciated!
Last edited by cart builder on Sat Apr 19, 2014 11:30 pm, edited 1 time in total.

New member

Posts

Joined
Wed May 15, 2013 7:11 pm
Location - England

Post by cart builder » Sat Apr 19, 2014 3:31 am

Basically, I need to add something to the following so that when the delivery image(icon) is clicked, it would be directed (linked) to the 'Delivery information' page in the standard OC Template.

In footer.tpl:

<div class="column">
<img src="image/data/delivery.png" style="position:absolute; margin-left:20px; margin-top:10px ; width:70px ; height:70px ;" alt=""/>
</ul>
</div>
<div class="column">
<h3><?php echo $text_information; ?></h3>
<ul>
<?php foreach ($informations as $information) { ?>
<li><a href="<?php echo $information['href']; ?>"><?php echo $information['title']; ?></a></li>
<?php } ?>
</ul>
</div>

So at the moment I just have an icon/image (that cannot be clicked to be redirected).

Please can somebody help !

New member

Posts

Joined
Wed May 15, 2013 7:11 pm
Location - England

Post by IP_CAM » Sat Apr 19, 2014 9:01 am

If I understand what you mean, have you tried something like this:

<div class="column">
<a href="<?php echo $information['href']; ?>"><img src="image/data/delivery.png" style="position:absolute; margin-left:20px; margin-top:10px ; width:70px ; height:70px ;" alt=""/></a>
</ul> ( What's this one doing here??? )
</div>

I wonder if >>$information['href']<< even produced a usable link, so, it would be better to adress the Page directly, not by using a variable.

Ernie

I don't use Forum Mail, to reach me, contact: jti@jacob.ch
-
Server Q & A Basic Information on Code + Settings
http://www.everyauction.info/serverinfo.html
Demoversion OpenCart LIGHT v.1.5.6.5
http://www.jti.li/shop/
1'400+ FREE OC Extensions - from OC v.1.5.x up,
on the world's largest OC-related Github Site: https://github.com/IP-CAM
-
Image


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland

Post by cart builder » Sat Apr 19, 2014 5:43 pm

Hi Ernie,

Many thanks for your help. Following your guidance, I have managed to create a clickable icon - it does however direct to the homepage - but at least I am now halfway there!

New member

Posts

Joined
Wed May 15, 2013 7:11 pm
Location - England

Post by IP_CAM » Sat Apr 19, 2014 9:49 pm

<?php echo $information['href']; ?>

I figured that the above href-link is not correct, because it lacks the href-content. It would probably have to be something like:

.... whatever.com/shop/index.php?route=information/information&information_id=4

So, try:

<div class="column">
<a href="http://www.whatever.com/shop/index.php? ... d=whatever">

where the last number seems to be a variable, therefore test Number 1,2,3,4,5,etc. to find the matching page.

I am not yet 'familiar' enough with this, because I never used it so far.

Ernie

I don't use Forum Mail, to reach me, contact: jti@jacob.ch
-
Server Q & A Basic Information on Code + Settings
http://www.everyauction.info/serverinfo.html
Demoversion OpenCart LIGHT v.1.5.6.5
http://www.jti.li/shop/
1'400+ FREE OC Extensions - from OC v.1.5.x up,
on the world's largest OC-related Github Site: https://github.com/IP-CAM
-
Image


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland

Post by cart builder » Sat Apr 19, 2014 11:29 pm

Hi Ernie,

Well done for finding the correct piece of script - the actual correct variable for the delivery page is "....information_id=6".

So thanks again for your kind help in getting this sorted !

New member

Posts

Joined
Wed May 15, 2013 7:11 pm
Location - England
Who is online

Users browsing this forum: No registered users and 52 guests