PDA

View Full Version : free song request system php script



xhilaration
05-29-2017, 05:08 AM
I have been searching on google for a free song request php script for my site. Ended up empty handed ☹️

As I don't know mysql, I need this script to be in php & non-mysql

I hope someone can help me out

Please let me know if anyone can make one for me. Thank you in advanced :)

saint
05-29-2017, 05:30 AM
You might want to go into a little bit more detail about what you want the script to do. A vague description of a request script could mean many things to many people.

James
05-29-2017, 05:58 AM
Where will the song requests be stored if you dont have mysql or some sort of database?
How will you be notified of song requests?

xhilaration
05-29-2017, 06:42 AM
You might want to go into a little bit more detail about what you want the script to do. A vague description of a request script could mean many things to many people.

I want the script to be able to let listeners request songs & have it to be sent to the on air dj that is on via skype. Remember yahoo msgr, where the listener clicked on the yahoo icon & it opens the yahoo msgr up. But I want the person do it like that but after they hit 'request', it will open skype msgr



Where will the song requests be stored if you dont have mysql or some sort of database?
How will you be notified of song requests?

I tried to make tables or what not in the phpmyadmin & it confuses me :( . I get totally lost as I try to understand how to set up a database :(

I have visited the php mysql tutorial site but that site makes it uber confusing to what to do :(

xhilaration
05-29-2017, 06:48 AM
Where will the song requests be stored if you dont have mysql or some sort of database?
How will you be notified of song requests?

I haven't thought of looking on youtube for how to set up a databasein phpmyadmin panel but I have read the tutorial on that site & it confuses me

Hope that I am not the only one it confuses them on making a database :(

James
05-29-2017, 07:01 AM
I want the script to be able to let listeners request songs & have it to be sent to the on air dj that is on via skype. Remember yahoo msgr, where the listener clicked on the yahoo icon & it opens the yahoo msgr up. But I want the person do it like that but after they hit 'request', it will open skype msgr

Sounds like you only need a Skype contact button.
https://www.skype.com/en/developer/create-contactme-buttons/

If you want something custom, you will need to dive into the Skype API. But that will only confuse you more since it sounds like you are fairly new to web development.
I would recommend simply adding a Skype messenger button on your website and instructing your users to click on that to open Skype and request a song from there. If you want anything further than that, then you will have to develop something custom yourself (using the Skype API), or hire someone to make it for you.

xhilaration
05-29-2017, 07:23 AM
Sounds like you only need a Skype contact button.
https://www.skype.com/en/developer/create-contactme-buttons/

If you want something custom, you will need to dive into the Skype API. But that will only confuse you more since it sounds like you are fairly new to web development.
I would recommend simply adding a Skype messenger button on your website and instructing your users to click on that to open Skype and request a song from there. If you want anything further than that, then you will have to develop something custom yourself (using the Skype API), or hire someone to make it for you.

I've builded websites on my iphone & on my laptop. Its just I tried to understand the phpmyadmin BUT it ends up confusing me so I give up on the whole phpmyadmin panel lol

But I have sites that are html via my iphone & my laptop for a long time so

it took me like a yr to try my hand on php

but now, I really want to learn the phpmyadmin panel area now!

just doin plain php, is ok but not exciting lol

James
05-29-2017, 08:14 AM
I've builded websites on my iphone & on my laptop. Its just I tried to understand the phpmyadmin BUT it ends up confusing me so I give up on the whole phpmyadmin panel lol

But I have sites that are html via my iphone & my laptop for a long time so

it took me like a yr to try my hand on php

but now, I really want to learn the phpmyadmin panel area now!

just doin plain php, is ok but not exciting lol

SQL and PhpMyAdmin won't help you in this case. You want functionality with Skype, so you will need to research the Skype API for integration.

xhilaration
05-29-2017, 09:09 AM
SQL and PhpMyAdmin won't help you in this case. You want functionality with Skype, so you will need to research the Skype API for integration.

And if I don't want to use the skype idea, will php & mysql work for me?

See where I get confused & lossed, after I set up the name of the database, its the values, what do I need & what do I need to set for the values

example:
name: - what value do I need to set it to like null or something
etc
etc
etc lol

James
05-29-2017, 09:56 AM
And if I don't want to use the skype idea, will php & mysql work for me?

See where I get confused & lossed, after I set up the name of the database, its the values, what do I need & what do I need to set for the values

example:
name: - what value do I need to set it to like null or something
etc
etc
etc lol

You'll need to structure a database for requests. Whatever fields you want to name.
e.g. id, name, phone number, song title, artist etc..

GKIye
05-29-2017, 01:14 PM
Hi James,

Should a similar button exist also for Whatsapp ?
To Me Whatsapp is more interesting than Skype ...
Into my data plan at my provider (smartphone) I have a special option to select a "free" app with unlimited up/download. I selected Whatsapp, so I'm available at any moment of the day (well ... unless I'm sleeping :rolleyes: )

Sounds like you only need a Skype contact button.
https://www.skype.com/en/developer/create-contactme-buttons/

xhilaration
05-29-2017, 05:20 PM
You'll need to structure a database for requests. Whatever fields you want to name.
e.g. id, name, phone number, song title, artist etc..

Yeah but I get lost what I need to put for em, I guess you would say permissions

name - Null - char - text

you wouldn't havr a picture of how this would be setup look like?

So I get the idea

Like I said, when I go into the phpmyadmin, I get lost & confused ☹️😟

James
05-30-2017, 12:33 AM
Hi James,

Should a similar button exist also for Whatsapp ?
To Me Whatsapp is more interesting than Skype ...
Into my data plan at my provider (smartphone) I have a special option to select a "free" app with unlimited up/download. I selected Whatsapp, so I'm available at any moment of the day (well ... unless I'm sleeping :rolleyes: )

You can use the WhatsApp API Link to launch the WhatsApp application on a mobile device:


https://api.whatsapp.com/send?phone=PHONENUMBER&text=YOURTEXTGOESHERE

Just replace PHONENUMBER with your WhatsApp phone number, and YOURTEXTGOESHERE with whatever text you wish the person to send you.
I could whip something up in PHP so that a user fills in a form and then it navigates to that URL with prepopulating text.


Yeah but I get lost what I need to put for em, I guess you would say permissions

name - Null - char - text

you wouldn't havr a picture of how this would be setup look like?

So I get the idea

Like I said, when I go into the phpmyadmin, I get lost & confused ☹️

A structure I would envision would be:


id int(100) AUTO_INCREMENT
name varchar(255)
email varchar(255)
songtitle varchar(255)
songartist varchar(255)
message TEXT
daterequested DATETIME default:CURRENT_TIMESTAMP

That would store the persons name, song title, song artist and an optional message. The database would store an ID (you always need a primary key) and record the date requested.

xhilaration
05-30-2017, 09:05 AM
You can use the WhatsApp API Link to launch the WhatsApp application on a mobile device:


https://api.whatsapp.com/send?phone=PHONENUMBER&text=YOURTEXTGOESHERE

Just replace PHONENUMBER with your WhatsApp phone number, and YOURTEXTGOESHERE with whatever text you wish the person to send you.
I could whip something up in PHP so that a user fills in a form and then it navigates to that URL with prepopulating text.



A structure I would envision would be:


id int(100) AUTO_INCREMENT
name varchar(255)
email varchar(255)
songtitle varchar(255)
songartist varchar(255)
message TEXT
daterequested DATETIME default:CURRENT_TIMESTAMP

That would store the persons name, song title, song artist and an optional message. The database would store an ID (you always need a primary key) and record the date requested.

Ty James ��
I get how to create a db but after not so much

ty again !!

xhilaration
05-30-2017, 02:07 PM
James
I found a part of an example code

CREATE TABLE 'request_song'


(`id` bigint NOT NULL auto_increment,
`song` longtext NOT NULL default '',
`artist` longtext NOT NULL default '',
`name` longtext NOT NULL default '',
`ip` varchar(100) NOT NULL default '',
PRIMARY KEY (`id`)
)
TYPE=MyISAM;


For the 'id' part, does it need to have a name for it?

Example:
'id' = request

or am I off??

:O

James
05-30-2017, 11:26 PM
James
I found a part of an example code

CREATE TABLE 'request_song'


(`id` bigint NOT NULL auto_increment,
`song` longtext NOT NULL default '',
`artist` longtext NOT NULL default '',
`name` longtext NOT NULL default '',
`ip` varchar(100) NOT NULL default '',
PRIMARY KEY (`id`)
)
TYPE=MyISAM;


For the 'id' part, does it need to have a name for it?

Example:
'id' = request

or am I off??

:O

'id' should be named 'id' as it's the unique identifier for the table. You can name it what you like but it wont make a difference.

saint
05-31-2017, 03:29 AM
One thing you need to remember in code development is KISS - keep it simple stupid. Creating a database for song requests ASSUMES that listeners know exactly what songs you have - OR - what artists you have. With the way data base hacks are being created - I would be leary of relying on that to "communicate" information to the on air DJ.

A simple message application could be incorporated into the station website to e mail or message the online DJ - no need to worry about API information related to Skype / whats app. When you start adding mega features to a basic concept - the obfuscation to the end results can be very harrowing.

I personally love to keep things simple - as it requires less maintenance and constant prodding. Just my two cents :)

James
05-31-2017, 03:40 AM
One thing you need to remember in code development is KISS - keep it simple stupid. Creating a database for song requests ASSUMES that listeners know exactly what songs you have - OR - what artists you have. With the way data base hacks are being created - I would be leary of relying on that to "communicate" information to the on air DJ.

A simple message application could be incorporated into the station website to e mail or message the online DJ - no need to worry about API information related to Skype / whats app. When you start adding mega features to a basic concept - the obfuscation to the end results can be very harrowing.

I personally love to keep things simple - as it requires less maintenance and constant prodding. Just my two cents :)

Agreed, I recently deployed a message feature for a station near me so that listeners could message the studio from their computer. Just set up a Slack API call, no need for a database or anything really.

xhilaration
05-31-2017, 05:52 AM
Guess that I prefer try my hand in a db & try to get myself to understand how mysql works. You can say that I like challenges hehe. Dab into db so my site would look good & I can say that I finally made a proper site with not only PHP but mysql as well :)

I tried using a plain jane email form in the past but now not so much thats my opinion :p. Yeah, keep it simple BUT I want it to look nice, crisp & clean as well !! :).

Im just a tad new to the mysql side vs the just php side of coding

:)

James
05-31-2017, 06:10 AM
Guess that I prefer try my hand in a db & try to get myself to understand how mysql works. You can say that I like challenges hehe. Dab into db so my site would look good & I can say that I finally made a proper site with not only PHP but mysql as well :)

I tried using a plain jane email form in the past but now not so much thats my opinion :p. Yeah, keep it simple BUT I want it to look nice, crisp & clean as well !! :).

Im just a tad new to the mysql side vs the just php side of coding

:)

Great way to learn too. Do what's best for you and your station.
Be sure to read up on SQL injection and keeping your SQL connection secure between MySQL and PHP. I recommend looking into PDO rather than traditional mysql_connect or mysqli_connect, far more secure.

xhilaration
05-31-2017, 06:23 AM
Great way to learn too. Do what's best for you and your station.
Be sure to read up on SQL injection and keeping your SQL connection secure between MySQL and PHP. I recommend looking into PDO rather than traditional mysql_connect or mysqli_connect, far more secure.

Kk, will do, thank you soo much James :)