This is the situation:
I have a music selling website developed with Smarty PHP by Agriya. The Buyer choose his music and "add to cart". In the PHP it is calling the music_id and goes on, get the price, title.....and everything it will need.
The future Situation should be that I want to sell 4 licenses for every music. So you have to develop only 2, the rest I will do on my own because I have a low budget for that.
Here is an example page how it should work.
[url removed, login to view]
If you click on +, four licenses will be open. It is only possible to get one of these licenses into cart. Try out. Like that it should work in the future in my cart.
You can work here with buttons for easier way. A modal window i can do later on my own. You have only to develop the license function into cart and delete function.
In the SQL Database there is now the row "music_price". I will integrate the row music_price_2
I have developed a little bit on my own, but I am not so good in PHP and had some Problems with commands like in_array and is_array. So I can help on some ways to get some variables or something like that. This is the way of files.
1. It is beginning in the .tpl file. The Button "Add to Cart"
var url = cfg_site_url+'music/[url removed, login to view]';
var pars = '?music_id='+music_id+'&&license='+license;
var path = url+pars;
So I have transmitted the music_id AND the license to another file.
3. There will be checked if the music_id is already in cart. If not, it will be done. Here is the Problem that it has to be checked if the music_id with the choosed license is already in cart.
4. Then it goes to the cart.php. Here is the actual situation that the price comes for the music_id from sql query and will be used in the whole script as $row['music_price']. This is very important, that it will work with that, neither if license 1 or license 2 choosed.
I had done that like that.
if license == '1' => then I have query the music_price from table
if license == '2' => then I have query the music_price_2 AS music_price from table
I can modify step 1+2 if you want. Default will be, that I will let everything like it is made by the developer agriya.
- You have to modify only 2 licenses for each music
- it has to work that music will be get into cart with the license it is choosed.
- overwrite/unset old license if new one will be choosed
- every price must work in the end as $row['music_price']; in [url removed, login to view]
- delete of music from cart has to work correctly
It is not urgent. So you have time enough to do that, due to my low budget.
10 freelanceria on tarjonnut keskimäärin %project_bid_stats_avg_sub_26% %project_currencyDetails_sign_sub_27% tähän työhön
i have gone through your requirement we done similar kind of job before looking forward your earliest Reply on this for a project discussion Awaiting for your earliest reply