Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 7 of 7
  1. #1
    Junior Member
    Join Date
    Jul 2008
    Posts
    10
    Member #
    17113
    Hey guys im new here and ive been through afew tutorials and can pretty much code a 1 page website with CSS html very comfortably. Im not sure if i have missed something along the line here but i am trying to create a blog like feature where you can post or submit news to the page. I'm assuming you use a form /text area however i dont know how you save that and then access it with php. Can anybody help? Thanks guys .

  2.  

  3. #2
    Senior Member
    Join Date
    May 2003
    Location
    UK
    Posts
    2,354
    Member #
    1326
    Hello.

    Unfortunately, something so simple (in terms of what you want to achieve - to save text) comes with a lot of fluff.

    For instance:
    How do you plan to stop anybody adding or editing the text on the page?
    What if you want to control the text on multiple pages?

    Luckily, there are ways round those 2 obstacles, but any solution depends on what exactly you are looking for.

    Do you want to be able to only edit 1 page?
    Do you have any database support on your hosting plan/server?

  4. #3
    Junior Member
    Join Date
    Jul 2008
    Posts
    10
    Member #
    17113
    Ok firstly thanks for replying.

    Now what i had planned was maybe on the page it says 'Click to add news' or something along those lines once you clicked this link i intended to take you to a login page where you input the admin user and pass and it proceeds you to the area where you input the news item which would then be updated on the homepage. If you put in a wrong user /pass then a javascript alert or something would pop up. Would this work? if so can you give me a little more info then i can probably suss it out myself.
    Thanks for your time.

    I have MySQL and apache for database however im not to sure how do use them properly.

  5. #4
    Senior Member
    Join Date
    May 2003
    Location
    UK
    Posts
    2,354
    Member #
    1326
    Thanks for the information.

    Does your host have any server side support? PHP, ASP(.NET), Perl, etc?

    All of these are capable of meeting your requirements.

    You are halfway there (you know the steps involved). Here is them clarified.

    1) On a page (lets call it login.html) you have a html form that accepts username and/or password. When the form is submitted the values entered are checked to see if they are correct. If they are correct, show a textarea with the content from your main page

    2) Make the changes as you see fit and then click update/save. The contents of the textarea are then saved back to file/database.

    3) The next time someone views your main page they will see the changes made.

  6. #5
    Junior Member
    Join Date
    Jul 2008
    Posts
    10
    Member #
    17113
    Thanks yes my host supports PHP. It can all be done with PHP then? its just a matter of me learning abit more about it?

    Thanks guys. you've been a real help i was about to give up

  7. #6
    Senior Member
    Join Date
    May 2003
    Location
    UK
    Posts
    2,354
    Member #
    1326
    Okay thats good.

    Here is a semi example of what you can do. I created a basic PHP/MySQL user script which can register new users and log them in and out. Obviously, you do not want the registering of new users but you do want the login/logout part.

    Also, you will see sensitive data (data that is only shown if you are logged in).

    I created a dummy account for you, if you go to http://www.andrewbuchan.co.uk/logger_demo you will see a login form. Use the details below

    Username = 12ecruit
    Password = 12ecruitpass.

    Once you have done that you will see text about Roger Rabbit etc. This is where you would have your form that you edit your front page news.

    Check http://andrewbuchan.co.uk/scripts/ for more information on Logger. There are without doubt better scripts out there but my one can at least show you whats involved.

  8. #7
    Junior Member
    Join Date
    Jul 2008
    Posts
    10
    Member #
    17113
    Thank you so much you seemed to have put alot of time into helping me and i owe you one. Thanks im going to mess around with it for abit untill i get it to work.


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 10:11 AM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com