AFemaleProdigy Posted April 25, 2012 Share Posted April 25, 2012 This should be pretty simple. I have added a section to AdminOrders.php with some information I needed to have available there. This information is originally listed on AdminCustomers.php and is edited in the customer account profile. I want to be able to click the edit link from the order page to edit this field. I tried to modify the link, but I am getting an Invalid Security Token error. Anyone know what I need to change to get rid of the error? Modified link added to AdminOrders.php: <a href="index.php?tab=AdminCustomers&addcustomer&id_customer='.$customer->id.'&token='.$this->token.'"> Original link copied from AdminCustomers.php: <a href="'.$currentIndex.'&addcustomer&id_customer='.$customer->id.'&token='.$this->token.'"><img src="../img/admin/edit.gif" /></a> Thanks! Link to comment Share on other sites More sharing options...
Ayacca Posted April 25, 2012 Share Posted April 25, 2012 Use https://addons.mozilla.org/fr/firefox/addon/live-http-headers/ and take a look at the token value(url). it will help you for sure. Link to comment Share on other sites More sharing options...
AFemaleProdigy Posted April 25, 2012 Author Share Posted April 25, 2012 What exactly will that do for me? How will that solve my problem with the url? I really don't want to install an unknown Firefox module written in a foreign language. I am just looking for suggestions about how to make this link work properly. It works fine when I use it on AdminCustomers.php. It just won't work on AdminOrders.php. Link to comment Share on other sites More sharing options...
AFemaleProdigy Posted May 7, 2012 Author Share Posted May 7, 2012 Help please? If anyone else thinks I should install that add-on, can I get some confirmation? I am leery of installing unknown applications. Link to comment Share on other sites More sharing options...
AFemaleProdigy Posted May 7, 2012 Author Share Posted May 7, 2012 Nevermind. I figured it out myself. This works... <a href="?tab=AdminCustomers&addcustomer&id_customer='.$customer->id.'&viewcustomer&token='.Tools::getAdminToken('AdminCustomers'.(int)(Tab::getIdFromClassName('AdminCustomers')).(int)($cookie->id_employee)).'&back='.urlencode($_SERVER['REQUEST_URI']).'"><img src="../img/admin/edit.gif" /></a> Link to comment Share on other sites More sharing options...
Ayacca Posted September 11, 2012 Share Posted September 11, 2012 sorry, i didnt answer before this addon is a very usefule tool which allow you to see the Http requests made by your browser(firefox). so you can see which value and which variable are sent in a POST or GET on a http request checking was is wrong with your token Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now