Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

hotspots and oscommerce


lindsayanng

Recommended Posts

Has anyone here used hotspots in dreamweaver or fireworks to create a navigation bar??

 

I'm just curious because i like to use hotspots a lot in my HTML sites, and they are pretty easy to work with when you hardcode the link into it, but i was wondering how you would do that with an oscommerce site where its not good to hardcode things like the shopping cart and products.. where you need to use PHP.

 

I'm pretty sure using it on the privacy, terms, shipping pages would be ok because they arent secure pages, just basic pages and hardcoding those isnt as bad.. but i would like to make a full navbar in illustrator, import it into fireworks and then hotspot it for a nav bar.

 

Any suggestions or ideas?

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

is this that stupid of a question that i shouldnt have asked it???

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

Some code examples might look something like this:

 

<MAP NAME="SHAPES">
<AREA SHAPE="POLY" COORDS="16,13,35,62,72,27,16,13" HREF="<?php echo tep_href_link(FILENAME_WHATEVER); ?>">
<AREA SHAPE="CIRCLE" COORDS="67,97,34" HREF="<?php echo tep_href_link(FILENAME_WHATEVER); ?>">
<AREA SHAPE="RECT" COORDS="129,28,175,108" HREF="<?php echo tep_href_link(FILENAME_WHATEVER); ?>">
<AREA SHAPE="RECT" COORDS="0,0,200,150" HREF="<?php echo tep_href_link(FILENAME_WHATEVER); ?>">
</MAP>

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Link to comment
Share on other sites

so i can make one and import it to dreamweave, use that code as a template to use tep_href link where ever there is a normal HTML link??

 

I was just thinking of making a fun navigation for my header, instead of my cheesey buttons, but i am MUCH better at doing an entire picture and mapping it. Can you do it while keeping the sessions and the customer logged it?

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

That would suffice for most links.

 

One's needing SSL would look something like this:

 

<AREA SHAPE="POLY" COORDS="16,13,35,62,72,27,16,13" HREF="<?php echo tep_href_link(FILENAME_LOGIN, '', 'SSL'); ?>">

And, as Jack said, as long as you use tep_href_link you shouldn't have any session/log the customer out problems.

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Link to comment
Share on other sites

wow.. THANKS A BUNCH.. this can take the look of my site in a whole new direction.. I can make a really neat right column

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

  • 1 month later...

I hate to resurect this old post, but i am revisiting my idea for hotspots in the new site that i am working on.

 

I get the idea of using the mapping code, but i am not sure where to add the usemap="#MAP3" in the image source.

 

My code looks like this for that image:

<td class="pageHeading" align="center"><?php echo tep_image(DIR_WS_IMAGES . 'contact.png'); ?></td>

 

I know that if using HTML, you would put it in the image attributes section like this:

<img src="email.png" width="720" height="200" border="0" usemap="#Map3">

 

I just dont know exactly what to do with php coding.

 

Any help is again, greatly appreciated.

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

this is what i have done so far which yielded an

unexpected "=" error

 

<td class="pageHeading" align="center"><?php echo tep_image(DIR_WS_IMAGES . 'contact.png', usemap="MAP3"); ?>
<map name="Map3">
				  <area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">
				</map></td>

 

<td class="pageHeading" align="center"><?php echo tep_image(DIR_WS_IMAGES . 'contact.png', usemap="MAP3"); <map name="Map3">
				  <area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">
				</map> ?>

 

i am just not sure where to put the code to make it work.

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

this is what i have done so far which yielded an

unexpected "=" error

 

<td class="pageHeading" align="center"><?php echo tep_image(DIR_WS_IMAGES . 'contact.png', usemap="MAP3"); ?>
<map name="Map3">
				  <area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">
				</map></td>

 

<td class="pageHeading" align="center"><?php echo tep_image(DIR_WS_IMAGES . 'contact.png', usemap="MAP3"); <map name="Map3">
				  <area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">
				</map> ?>

 

i am just not sure where to put the code to make it work.

 

Your missing 3 arguments for tep_image (the alt, width and height)

 

change this your tep_image call from this

 

<?php echo tep_image(DIR_WS_IMAGES . 'contact.png', usemap="MAP3");

 

TO THIS:

 

<?php echo tep_image(DIR_WS_IMAGES . 'contact.png', 'Contact us', '', '', 'usemap="MAP3"');

 

 

Lemme know how you go

Link to comment
Share on other sites

THANK YOU!! and then do i put the map before or after the closing php tag??

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

hmm. i tried both putting this:

 

<map name="Map3">

<area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">

</map></td>

 

Both inside and outside the <?php tag and nothing.

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

In the code for the image you need the USEMAP

 

<td class="pageHeading" align="center"><img src="images/contact.png" alt="" width="239" border="0" height="48" USEMAP="#Map3"></td>

A working example:

 

Image Map

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Link to comment
Share on other sites

i have that, if you read the code above, i was trying to use the tep_ref way of linking though, instead of the basic html> Is this not possible?

 

I have the USEMAP in there, but i dont know how to make the links that are inside of the map keep the sessions, which i dont believe html can do, correct?

 

please take a look at the most recent posts. I figured out HOW to do it as far as making a map with shapes an such, but i can not incorporate it into PHP.

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

I wasn't suggesting to use HTML.

 

Rather pointing to a code flaw I noticed, or thought I did.

 

I've never used image maps. I'm just using a "go by" that works.

 

echo tep_image(DIR_WS_IMAGES . 'contact.png', 'Contact us', '', '', 'usemap="MAP3"');

That format as it was posted should work.

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Link to comment
Share on other sites

right. I know that that format will work, but do you know if i put the ACTUAL map inside or outside of the php tags?

 

This part of the mapping code?

 

<map name="Map3">

<area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">

</map> ?>

 

I'm not sure where to put it. Where ever i put it (see above) i get errors.

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

<map name="Map3">
<area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">
</map>

That's just HTML.

 

It can go OUTSIDE php tags just as it is.

 

INSIDE tags it need to be something like:

 

<?php echo
'<map name="Map3">' . "\n" .
'<area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">' . "\n" . 
'</map>' . "\n"; ?>

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Link to comment
Share on other sites

hmm.. Thanks. I will try that, because when i put it outside the tags, i got no error, but also no link.

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

ok.. this is what i had, and i am STILL not getting a link!

 

<tr>
<td class="pageHeading" align="center"><?php echo tep_image(DIR_WS_IMAGES . 'email.png', 'Contact us', '', '', 'usemap="MAP3"'); '<map name="Map3">' . "\n" .
'<area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">' . "\n" .
'</map>' . "\n"; ?></td>
</tr>
	</table>

 

I also did this

<tr>
<td class="pageHeading" align="center"><?php echo tep_image(DIR_WS_IMAGES . 'email.png', 'Contact us', '', '', 'usemap="MAP3"');  ?>
<map name="Map3">
<area shape="rect" coords="115,106,600,163" href="mailto:[email protected]">
</map></td>
</tr>
	</table>

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

wow.. never mind. i got it to work. I used the second code, with the html outside of the php and inside of the </td> BUT the only thing it REQUIRED was "#" before usemap="#MAP3"

 

I looked at the map inside of dreamweaver and saw the # and put it in there and VOILA

A great place for newbies to start

Road Map to oscommerce File Structure

DO NOT PM ME FOR HELP. My time is valuable, unless i ask you to PM me, please dont. You will get better help if you post publicly. I am not as good at this as you think anyways!

 

HOWEVER, you can visit my blog (go to my profile to see it) and post a question there, i will find time to get back and answer you

 

Proud Memeber of the CODE BREAKERS CLUB!!

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...