Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3952998
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T01:55:18+00:00 2026-05-20T01:55:18+00:00

I have an application that create child’s gifts applications, and every application owner can

  • 0

I have an application that create child’s gifts applications, and every application owner can add own gifts, right now i’m storing gifts in a php array :

<?php
$gifts_array = array(
array(>4,"Flower",>250,"5_250.jpg",301),
array(1,"a Good Day",30,"3_30.jpg",153),
array(2,"cat",10,"3_10.gif",139),
array(3,"batman",20,"2_20.jpg",101),
array(11,"White Wolf",100,"11_100.jpg",5),
array(10,"crazy cat",30,"10_30.gif",2),
array(8,"Gift",100,"6_100.jpg",2),
array(12,"Car",120,"12_120.jpg",1),
array(9,"cat 2",30,"9_30.gif",1),
array(7,"2Pac",500,"3_500.jpg",0),
array(6,"Outlawz",500,"4_500.jpg",0)
);
?>

I need to update gift counter every time sent, so i have to do a loop to find the gift then increment and write the whole array in the file.

It is good to create this Array like that :

    '100'=>array('gname'=>"Flower",'gpoints'=>250,'gpic'=>"5_250.jpg",'gviews'=>301),
     100 is the Gift ID.

What is the best solution :
– Create for every application a MySQL table ?
– Use one Table for all applications ?
– Use one MySQL table to store all apps gifts and cache MySQL results for each application after Gift INSERT/UPDATE/DELETE ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T01:55:18+00:00Added an answer on May 20, 2026 at 1:55 am

    Just create one table with the same number of columns, plus one identifying which “application” it corresponds to. Don’t create a new identical table for each app, and don’t keep reading/writing from a text file, both are concurrency and maintenance nightmares.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have built a MS Access 2007 application that can create reports files in
Can I create an application with Flex Builder Trial ( that I have just
i have an Java J2ME application that does (at user request) create HttpConnections to
I have to create a user in a third party application that stores its
I have a requirement to create a simple windows forms application that allows an
I have a WPF application where I'd like to create a custom pop-up that
I need to create a plug-in that updates an application. Look, I have a
I have an application that spawns multiple child processes. Before launching a child, I
I have my main application, which contains several instances of a component that create
I have a web application that I'm trying to create a Web Deployment Project

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.