SitePoint Sponsor

User Tag List

Results 1 to 2 of 2

Hybrid View

  1. #1
    FBI secret agent digitman's Avatar
    Join Date
    Sep 2004
    Location
    Work
    Posts
    697
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    storing user settings?

    I'm coding this website where people need credits to do stuff on the site. They have to buy the credits as you guessed.

    The client wants to have an admin panel where he can change the price of the credits, e.g if the price of 1 credit is 1 cent, 100 credits would be a dollar. The client wants to be able to change the price of this 1 credit in future. Also he wants to be able to specify a "processing fee" to the transaction. For example, he wants to specify 3.5% of the total cost of the credits + .35 as the processing fee, if the money is being paid through PayPal, and wants to be able to change that in future.

    How can I store all of these settings? I know I could use a seperate table in a MySQL database but I feel there's no point of it, and that there must be an easier way. I want to store this information in such a way that I could simply read from a file / include it and I'd be able to not only get the values of these settings but also change them. Please give me some suggestions on how to do that, or tell me how you store the settings in your php apps?

  2. #2
    $this->toCD-R(LP); vinyl-junkie's Avatar
    Join Date
    Dec 2003
    Location
    Federal Way, Washington (USA)
    Posts
    1,526
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    In my opinion, there is no easier way of storing this information than in a table within your database. You could store it in a text file, but that wouldn't make it any easier to retrieve and/or update the data; in fact, it would probably make it more complicated.

    As far as maintaining the data itself, you probably want to have a screen with the updateable data and give access to that screen via some sort of authentication system.

    Hope this helps.
    Music Around The World - Collecting tips, trade
    and want lists, album reviews, & more
    Showcase your music collection on the Web


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
  •