Results 1 to 3 of 3

Thread: Dynamically updating a webpage with another...

  1. #1

    Thread Starter
    New Member
    Join Date
    May 2005
    Posts
    2

    Dynamically updating a webpage with another...

    Hi,

    Ill briefly explain my situtation. I am implemeting a small system that has an administrator side and a user side.
    My user side has a page called news.aspx that simply contains basic lines. TO be exact:

    news.aspx:



    <html>
    <body>
    This is the news bulletin area
    </body>
    </html>

    Here is what i wanna do:
    FROM THE administrator, i want to be able to update the news on that page by allowing a the administrator to type in recent news and simply pressing a button "post" that will update news.apsx.
    The update can occur in ONE of two ways:
    1- replace the line "this is the news bulletin area" with the news the administrator posted
    2- simply add above it the recent news (i would prefer this one since i can keep track of all the news posted)
    .......
    .......
    .......
    Let us say for the sake of conversation, the administrator page is called postnews.aspx. I have already linked the two sides (admin and user) and they are split with a login area, in which u can go either way.
    How can i do what i need to do above?
    (i think i might need a text box and somehow using c# re-write or write-to the news.aspx)

    Thank you for your help.

    Sam

  2. #2
    Hyperactive Member The_Duck's Avatar
    Join Date
    May 2005
    Location
    Leamington, UK
    Posts
    351

    Re: Dynamically updating a webpage with another...

    Hello!

    An important concept in web design is to seperate your logic from your data. In your situation your data is the news items, and your logic is the displaying web page.

    Rather than try and 'edit' your logic (!) I would recommend that you only edit your data.

    A simple method would be to place your news items into a text file. You could simply have this text file read in as a frame in your web page.

    A more common approach is to store your news items in a database. You can then read these items back from the database.

    Commonly web pages such as this will have two or more different views. The first is the users perspective - which provides a read only interface. When using ASP you can then provide a login system and check the access levels for the user. Should they have sufficient privilages you can then add an additional section to your page that allows them to edit the content - by writing additional entries to your database !

    Hope this sets you on the right track, Good Luck !

  3. #3

    Thread Starter
    New Member
    Join Date
    May 2005
    Posts
    2

    Re: Dynamically updating a webpage with another...

    thnx alot for the help mr.duck...
    that actually did help....!

    Sam

Posting Permissions

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



Click Here to Expand Forum to Full Width