Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New Coder
    Join Date
    Apr 2012
    Location
    California
    Posts
    12
    Thanks
    6
    Thanked 0 Times in 0 Posts

    CSS enchancement occassionally disappear in a database driven website

    Hello Friends,

    I am developing my skills in PHP and MySQL by copying all the PHP codes and database tables of a complete e-commerce site from a book.

    One of the tables in the database is "product". I added a few columns (date starts, date end, etc.) in order to practice. When I go to browser to retrieve "product list" coming from home page, I have notice that their are chances the HTML page would show WITHOUT the CSS enhancement. I tried going to another page such as "contact page" and the CSS enchancement is intact. Then I tried going back once more to product page but this time the CSS enhancement is present. Any idea why this happening and please help me how to fix this. I am using XAMPP. Thank you in advance.

    espi62

  • #2
    Senior Coder
    Join Date
    Jan 2011
    Location
    Missouri
    Posts
    4,316
    Thanks
    23
    Thanked 613 Times in 612 Posts
    Nobody here has the book your using or access to your code so we don't know.
    1.) Please post the code your having trouble with. - That would be the php used in querying your DB. The HTML if it's seperate from the php and the CSS used on the HTML page.
    2.) Since you say this now working do you still have a problem. LIKE, does the styling not work the first time you go to the page?
    Evolution - The non-random survival of random variants.

    "If you leave hydrogen alone, for long enough, it begins to think about itself."

  • #3
    New Coder
    Join Date
    Apr 2012
    Location
    California
    Posts
    12
    Thanks
    6
    Thanked 0 Times in 0 Posts

    Smile CSS enchancement occassionally disappear in a database driven website

    Hello Sunfighter,

    Thank you very much for your reply.

    It will require a lot of code posting since the codes are in the MVC form.

    What I did is to add 3 table columns for product table but I did not change any in php, html, css scripts. As i have mentioned, this is a book sample about a completed e-commerce website. It worked totally fine (php, mysql, html) before adding those columns in the MySQL database. The malfunction consists of the index page appearing without CSS connection when you open the web page. Then if I go to another page, like categories, there is a CSS connection.

    I was wondering if you can give any idea why this is happening. Thank you.

    espi62

  • #4
    Senior Coder
    Join Date
    Jan 2011
    Location
    Missouri
    Posts
    4,316
    Thanks
    23
    Thanked 613 Times in 612 Posts
    You are correct I don't want to see MVC. But you had to use that to generate PHP code to access your DB and write a web page. That's what I want to see; the PHP and if needed the HTML.
    Evolution - The non-random survival of random variants.

    "If you leave hydrogen alone, for long enough, it begins to think about itself."

  • #5
    New Coder
    Join Date
    Apr 2012
    Location
    California
    Posts
    12
    Thanks
    6
    Thanked 0 Times in 0 Posts
    Hello Sunfighter,
    I went back to the same php and mysql database files and surprisingly it is now working fine. It could have been a glitch in xampp. I restarted my computer previously but it wasn't working well. Since I did not access these files for a day now it is working fine.

    Thank you very much for your help.

    espi62

  • #6
    Senior Coder
    Join Date
    Jan 2011
    Location
    Missouri
    Posts
    4,316
    Thanks
    23
    Thanked 613 Times in 612 Posts
    So glad you fixed things
    Evolution - The non-random survival of random variants.

    "If you leave hydrogen alone, for long enough, it begins to think about itself."

  • Users who have thanked sunfighter for this post:

    espi62 (05-29-2014)


  •  

    Tags for this Thread

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •