Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Onclick close and refresh with tep_href


desiredin

Recommended Posts

I have my login page to come up in a Lightbox/Shadowbox style manner, however I would like to call the close function to close the shadowbox when I either click the log in to submit the login form, or click the new customer continue button. And want the results/link refreshed in the parent window.

 

I am sure I will get an annoyance issue of having to click back to the login page when the wrong e-mail address or password is submitted, but I'll take these things one step at a time. Heh.

 

I assume the code below is where I need to call the onclicks from. However, I have no idea how to use the formatting of it. I keep getting nothing but T string errors as I'm basically doing trial and error, but not really knowing/understanding what I am doing.

<td align="right"><?php echo '<a href="' . tep_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL') . '">' . tep_image_button('button_continue.gif', IMAGE_BUTTON_CONTINUE) . '</a>'; ?></td>
<td width="100%" valign="top"><?php echo tep_draw_form('login', tep_href_link(FILENAME_LOGIN, 'action=process', 'SSL')); ?><table border="0" width="100%" cellspacing="0" cellpadding="0">

 

Can anyone with knowledge in this area give me a hand with accomplishing this please?

Link to comment
Share on other sites

I have figured out getting the create account link working. Would appreciate getting it working with the variables to this can be adapted easily for using other languages, etc. But for me, this will work fine.

<?php echo '  <a href="create_account.php" onClick="parent.location.href=\'create_account.php\';parent.Shadowbox.close()"><img src="/includes/languages/english/images/buttons/button_continue.gif" border="0"></a>'; ?>

 

But I still need to figure out the login portion of it.

<?php echo tep_draw_form('login', tep_href_link(FILENAME_LOGIN, 'action=process', 'SSL')); ?>

Link to comment
Share on other sites

To clarify what I did to get the first example working, was I removed the tep_href and specified the link and image. So it is not pulling any lanugage files or images. Just realized I will have to change it for SSL as well. But it's a start. Heh.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...