Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

change quantity update button into text link?


robster2

Recommended Posts

No shit Sherlock.. the point is how to get the update function to work with a text link instead of a tep_draw button.

Lots of info here on how to remake a text link to a button but not the other way.

Link to comment
Share on other sites

Well I figured out that to copy the "remove" code and make an action=submit could be a solution just dont know exactly how

 

something like:

From: <a href="' . tep_href_link(FILENAME_SHOPPING_CART, 'products_id=' . $products[$i]['id'] . '&action=remove_product') . '">

To:    <a href="' . tep_href_link(FILENAME_SHOPPING_CART, 'cart_quantity=' . $products[$i]['id'] . '&action=submit') . '">

 

As you can see my php knowledge is 0 but it should be possible somehow Im sure.

Link to comment
Share on other sites

You can't do that, because action=submit means nothing to the script, unless you want to set this in application_top.php and I don't know what else would be necessary

 

Conclusion: forget about removing the submit button of the form

 

Only way is, to "un-style", or "re-style" it with css, so it doesn't look like a button any more

 

Wrap it into a selector, like e.g. "no_button" and then target it in css like

 

.no_button button{background:none;border:none;} and any other rules you want

Link to comment
Share on other sites

Ok thanks, with the selector, do you mean like  no_button instead of tep_draw_button, If so how do i proceed?

 

Have tried to style the button in css by labeling it like "null, 'secondary123' but It can only control borders, background and font weight, hover and text size is not possible.

 

Thanks in advance!

Link to comment
Share on other sites

With "selector" I mean to wrap in into a html element and give a class to that element.

 

<div class="kuku"> the button </div>

 

In this case you target like .kuku button {} in css

 

 

You can also give a class to the button itself, adding parameters to the end of the button function

 

array('params'=> 'class="kuku"')

 

Here you target like button.kuku{} in css

 

I'm using "kuku" to make clear that the class name has no effect, it is just anything

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...