![]() |
where i customer/secure_login.php
on 4 0 18? i looked everywhere man. the closest i found is secure loging form tpl. |
Version 4.0.x+ secure_login.php is directly under xcart/ and NOT customer/
As for categories and location not showing up you'll need to include the, include/categories.php file and define a "location" variable via $smarty->assign within your php. :wink: |
Does secure_login.php need to have an SSL installed?
How do i make it so that secure_login.php doesnt need the https in front of it? |
boomer, you know how xcart just lists all the ROOT categories on the left side by default, well i dont want that.
i want that area to only show the subcategories based on the Root cat. example - I have 2 main/root cats CAT1 CAT2 Only When visitor clicks on CAT1 then left menu will list in the subcats of CAT1. Only When visitor clicks on CAT2 then left menu will list in the subcats of CAT2. Ofcourse, it has to work in such a way that if i add cat 3, 4, 5 ,6 and so on, it will automatically do this. i found this http://forum.x-cart.com/viewtopic.php?t=25470&highlight= but i dont know if thats what i need. |
Look around the General Settings area in X-Cart's Admin ;)
Quote:
|
lolol wow that was the easiest. i was killig myself.
lolololol wow i feel stupid, and balinor is probably, saying "this guy doesnt read the manual" 4 things happenened when i unticked it. 1. i lost the little gifs before the sub cat name. now is just a link. the rest of the css is ok. im on 4 0 18 and could it be cuz theres 2 menu menu.tpl menu_customer.tpl I'll looke for the answer. 2. if the subcat, doesnt have subsubcats, the box is empty and looks ugly. is not a big deal, as of yet. this is one in need advice on mate. 3. if customer not on any categeroy, it shows the root menu. instead of the root menu, can i disable it so that it doesnt show it? instead, i would like to show the hept.tpl menu or something else that i can make up. |
boomer, you being the master of css,
i tried putting a current css on the menu but it didnt work. my dreamweaver css attribute didnt recognize the command current if visitor is on cat1 or a subcat, to high lit the background permantently for as long as the visitor is on that category. |
any ideas how to do this in my version of xcart as I have tried the one that worked in 3.5.5 and it does nothing.
or is there a real simple way now that i'm totally missing? cheers sticky |
Copied Laureon's mod and the following error occurs
Warning: main(./auth.php): failed to open stream: No such file or directory in /home/xxxx/public_html/xxxxx/customer/myaccount.php on line 2 here is the php file <? require "./auth.php"; require $xcart_dir."/include/categories.php"; $smarty->assign("main", "myaccount"); $smarty->assign("location",$location); $smarty->display("customer/home.tpl"); ?> Anyone know how to fix the error |
yages, i guess u fixed it cuz ur page is working.
|
Re: Login Link
Thanks a lot. Great idea!
|
Re: Login Link
Quote:
I want to combine three templates into one page. I can't figure out how they are called. I don't need to edit the templates themselves, just have them all on the same page. Here's specifics: I have 3 separate pages as follows login = secure_login_form.tpl registration = register.tpl recover lost password = change_password.tpl these all come up on separate pages, I want them all on one. My home_main.tpl includes this: {elseif $main eq "register"} {include file="customer/main/register.tpl"} {elseif $main eq "secure_login_form"} {include file="customer/main/secure_login_form.tpl"} {elseif $main eq "change_password"} {include file="customer/main/change_password.tpl"} I'm not sure what file I need to modify. |
Re: Login Link
i couldnt get this to work. so what i did was duplicate this page - xcart/error_message.php?need_login. i'm not sure what unnecessary code can/should be removed from the duplicated file beyond what i've already removed so that it continues to work but...
create a file called myaccount.php and insert the following code Code:
<?php then upload it to /xcart directory. then in skin1/common_templates.tpl add the following... Code:
{elseif $main eq "myaccount" or $main eq "antibot_error" or $main eq "disabled"} then add the link to your page http://www.mysite/xcart/myaccount.php where you want it to appear. |
Re: Login Link
if it helps anyone, here's how i displayed the login link if logged out and vice versa...
Code:
|
Re: Login Link
Quote:
I don't really understand why you would want them all on the same page, particularly since they do different things. "Register" does just that, registers new customers. "Secure Login" will login current customers using https. "Change Password" will allow current customers to change their password, and is part of "modify profile". "recover lost password = change_password.tpl" as you state is incorrect. "Recover Password" allows a current customer to retrieve their login information via email and has nothing to do with changing their password (unless of course you require them to change it at their next logon). Anyway, to get more than one template on a page, just call it... {elseif $main eq "whatever_you_want_to_name_your_page"} {include file="customer/main/register.tpl"} {include file="customer/main/secure_login_form.tpl"} {include file="customer/main/change_password.tpl"} You need to include the "requires" on "whatever_you_want_to_name_your_page.tpl" |
Re: Login Link
I'm running X-cart 4.1.11 and to get a login page, I just link to secure_login.php. Ideally you should use https, but either way. I'm not sure how long this program has been part of X-cart.
|
Re: Login Link
I've copied updated Laureon's mod with your code above. Now, I need to remove the previous {if $login ne ""} info and include what you have posted. Can you direct me where this should go in the myaccount.tpl?
I will also be adding a 'password protect' register login for this new login page. Any suggestions are welcome. Christine Quote:
|
Re: Login Link
Boomer,
I've tried both your code and Laureon's, but I'm not having any luck. When I used your suggestion to copy the code from my site login_form.tpl <form> </form>, I could see the code and no way to submit. When I used your code and corrected any portion that points to your /lab/, then the login page shows, but still no submit button. Any suggestions? Christine Quote:
|
Re: Login Link
Hi Christine,
In the sample code you posted it is showing a link to: skin1/images/buttons/submit.gif I believe you will find no such file in your 4.1.x version of X-Cart. There is now a skin1/buttons/ folder and inside you will find submit.tpl (TPL not GIF). In place of the submit button, you may be able to use: {include file="buttons/login_menu.tpl"} Also, compare the source code on one of your existing web site login pages. The customer login page uses this template: customer/main/secure_login_form.tpl And here is part of the Submit Button code from that template: {if $js_enabled} {include file="buttons/submit.tpl" href="javascript:document.secureform.submit()" js_to_href="Y"} {else} {include file="submit_wo_js.tpl" value=$lng.lbl_submit} {/if} </td> </tr> </form> The above code shows how they are including the file: buttons/submit.tpl if Javascript is enabled, else include submit_wo_js.tpl Both submit.tpl and login_menu.tpl then include file="buttons/button.tpl" to create the Submit button image. One of those methods should work for you. Just work on a copy of the file and a test site (if you have one available). Robert |
Re: Login Link
Thanks for your reply. I've made some progress with the login page, but I am having trouble with the submit-login button. I tried your code and your suggestion using {include file="buttons/login_menu.tpl"} with my original code from auth.tpl. Tonight the link is working in IE7, but earlier today it didn't work in Safari or Firefox. Do you have any suggestions for me to password protect register.php?
Christine Quote:
|
Re: Login Link
Quote:
That is already built into X-Cart. Just go to: Admin --> General Settings, then select the "Security Options" sub-menu link. Under there you will find: HTTPS options: Use HTTPS for users' login and registration: (CHECK this box) If instead, you actually want to password protect the register.php file, you can do that via C-Panel, and choose: Password Protect Directories. However, anyone who attempts to register will get a pop-up asking for the Username and Password. Robert |
Re: Login Link
Hi Robert,
Yes, I want to do the later part of your suggestion, to password protect register.php file. Per your suggestion, I checked our cpanel Password Protect Directories, though this only allows to protect an entire folder. Do I need to move my register.php to it's own folder to acheive this? Christine Quote:
|
Re: Login Link
Quote:
Try this... go back to your cPanel --> "Password Protect Directories". 1. Click on a Folder Icon (not folder name) to open it, such as: public_html 2. Keep doing this until you get to the lowest possible folder that contains the file you want to protect, such as: register.php Add the folder protection to that lowest sub-folder. Go back to your web site via FTP and download the new .htaccess file that was added to that lowest sub-folder you just protected. In the .htaccess file will be text such as: AuthType Basic AuthName "Restricted Access" AuthUserFile "/home/[username]/.htpasswds/public_html/passwd" require valid-user Next, you will need to modify the .htaccess file so the protection applies to a single specific file using the <files> tags, as follows: <Files [filename]></Files > To protect the file "register.php", you would modify the .htaccess statement as follows: <Files register.php> AuthType Basic AuthName "Restricted Access" AuthUserFile "/home/[username]/.htpasswds/public_html/passwd" require valid-user </Files> Preferably, test this on a test site, or a less important file, before taking it live. Robert |
Re: Login Link
anybody get this working in 4.2x without an SSL?
I've made a file in main catalog root "mainlogin.php" that I used the code from secure_login.php and commented out the following. Code:
<?php It displays the form fine but on login tries to go secure (https) and we don't have an ssl and don't plan on using one for this site... how do I bypass the secure login stuff? |
Re: Login Link
Hi Robert,
I really want to try your suggestion! I've been back to my cpanel and I can get to the lowest-folder of /store/ and I add the name of the protected directory, though it protects the entire store instead of just the register.php. Do you know if I need to add/change something in the register.php to make this work? Christine Quote:
|
Re: Login Link
Quote:
I have not tried it on a root-level file, but just make sure that after you applied the Password Protection via cPanel to your /store/ directory, that you then login to your store's server via FTP and download the new .htaccess file that was just created. NOTE: You should first make sure you backup your old .htaccess file in case you want to revert, before applying any password protection in cPanel, because that will overwrite your old .htaccess file. Once you have downloaded the new .htaccess file, make sure you add the <Files> lines at the beginning and end of the .htaccess code block to specify which file to assign the Password protection to (i.e. register.php in our example): <Files register.php> </Files> See the full example in my previous post. If that does not work, then someone else will need to jump in with another idea. Robert |
Re: Login Link
Awesome, this works! Thank you Robert.
Christine |
Re: Login Link
I created a new static page and I'm using Boomers mod for the login. My problem is the location always directs to the current page -- which happens to be the static page. Once the login passes I want the customer to be directed to either their cart if there's any items selected in their cart else they'll go to the home.php. Any suggestions?
|
Re: Login Link
Christine,
Try adjusting the VALUE of the Redirect statement of your login template... <input type="hidden" name="redirect" value="{$redirect}" /> Try setting the value="http://www.YourHomePage.com" for starters. You will need to add some IF - ELSE logic if you want to check their cart for contents, else go to the homepage. Robert |
Re: Login Link
I am lost
here is what I have done edit [skin1]/common_templates.tpl and add: Quote:
I add it that on the end of common_templates.tpl step 2 I created a new tpl customer/main/login.tpl and past the auth.tpl in it Now just create the login.php file, with: Quote:
the result http://www.prestigedentalproducts.com/customer/login.php it redirect me to http://www.prestigedentalproducts.com/customer/index.php Not Found I have tried all different ways nothing worked !!!!!!!!!!!!!!!! I have x-cart-4.3.2gold |
All times are GMT -8. The time now is 11:13 PM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.