Results 1 to 4 of 4
  1. #1
    Join Date
    Aug 2007
    Posts
    18
    Plugin Contributions
    0

    Default Couple of questions - username, and detect if logged in.

    OK, I am not making an addon as such, I just have a PHP file and I want to echo the current username.

    So I can use $account->fields['customers_email_address'], but what file(s) do I have to include/require or use some othe function?

    And how do you see if a user is logged in, so to display a link only if a user is logged in to your copy of Zen Cart,

    Thanks,

    BP

  2. #2
    Join Date
    Aug 2007
    Posts
    18
    Plugin Contributions
    0

    Default Re: Couple of questions - username, and detect if logged in.

    Damn, 7 minute editing limit:S

    PHP Code:
    include($_SERVER['DOCUMENT_ROOT'].'/store/includes/application_top.php'); 
    And just got errors, so is there something else I need to declare?

    Code:
    Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/doghouse/public_html/store/join.php:5) in /home/doghouse/public_html/store/includes/functions/sessions.php on line 108
    
    Warning: Cannot modify header information - headers already sent by (output started at /home/doghouse/public_html/store/join.php:5) in /home/doghouse/public_html/store/includes/init_includes/init_templates.php on line 78

  3. #3
    Join Date
    Aug 2007
    Posts
    18
    Plugin Contributions
    0

    Default Re: Couple of questions - username, and detect if logged in.

    No one?

    Can I at least use PHP in EZ Pages, so the variables are built in?

    Cheers,

    BP

  4. #4
    Join Date
    Sep 2007
    Location
    Dublin, Ireland
    Posts
    1,288
    Plugin Contributions
    8

    Default Re: Couple of questions - username, and detect if logged in.

    "Cannot modify header information - headers already sent by..."

    usually means there's crap like whitespace at the top of your file
    Andrew

    Andrew Moore
    Omnicia Agile Development
    www.omnicia.com

 

 

Similar Threads

  1. Site Tagline and a couple of other questions
    By sharon72 in forum Templates, Stylesheets, Page Layout
    Replies: 10
    Last Post: 15 Jul 2011, 01:00 AM
  2. A couple of questions. (Layout of image and centering)
    By RiemenDesign in forum Templates, Stylesheets, Page Layout
    Replies: 10
    Last Post: 11 Dec 2008, 10:28 PM
  3. How to detect if logged in?
    By monkeyjr47906 in forum General Questions
    Replies: 3
    Last Post: 3 Dec 2007, 05:48 PM
  4. Moving copyright info and couple other questions
    By LoriW. in forum General Questions
    Replies: 7
    Last Post: 8 Jul 2007, 05:07 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR