cool. k did you look at the barebones code? It needs a lot of work, but i need some help on some things. Like how do you won't to see latest uploads so you can approve them?
Offline
ProgrammingFreak wrote:
cool. k did you look at the barebones code? It needs a lot of work, but i need some help on some things. Like how do you won't to see latest uploads so you can approve them?
How do I want to see them? Preferably as they saw it just before they clicked SUBMIT so that I get the form they looked at, with the text they entered into each of the boxes (and radio's ticked) like they had it. Then a mod can make changes to any part of the form if they need to, before clicking [approved] at the bottom to load it to the main library.
(that's the plan, anyhow)
Offline
k, how would i do that? Idk how to make it where text is already in the stuff.
maybe: echo "<input type=/"text/" value=/" '$name'/" " ?
so do we have a database?
Offline
fg123 wrote:
Told you I have to set up everything first. WE start on wednesday...
oh sorry.
um, do you have some advice on my code?
Offline
hmm, so i've got this so far. it doesn't do anything really. do you do like
echo "<p>'$name'"</p>"
for him to view the uploads. Here is the barebones:
<form method="post"> <h3>Share a Block!</h3> <p>Do you have a block that you would like to share to the<br> Scratch World? You've come to the right place</p> <tr> <td> <p>Name of Block:</p><input type="text" size="50" name="name"> </td> <td><p>BlockSpec: <input type="text" name="spec"size="400"></p> </td> <td><p>Code: <input type="text" name="code" size="400"></p> </td> <td> <p>Block's Mod:</p> <select> <option name="Panther" value="Panther"> <option name="BYOB" value="BYOB"> </select> </td> <td> <p>Notes:</p><input type="text" name="notes" size="400"> </td> </tr> </form> <?php $name = $_POST['name']; $mod = $_POST['mod']; $notes= $_POST['notes']; $spec = $_POST['spec']; $code = $_POST['code']; ?>
its definatly not finished yet!
Offline
Now, i know how to make it send it to an email. i just don't get how you would view it like Daffy22 is talking about.
Offline
Okay this is my idea for the whole upload system...
1. The use fills in a form that allows them to submit their block
2. The PHP script then writes it all to a temp file in a temp folder
3. Sparks (or other modertors) then have to approve it before it is added to the main list of blocks which is viewable to the public
Hows that sound? any ideas? Programming help would be appreciated!
Offline
Daffy22 wrote:
Okay this is my idea for the whole upload system...
1. The use fills in a form that allows them to submit their block
2. The PHP script then writes it all to a temp file in a temp folder
3. Sparks (or other modertors) then have to approve it before it is added to the main list of blocks which is viewable to the public
Hows that sound? any ideas? Programming help would be appreciated!![]()
so it writes to a file ehh? I can do that. But what is a .temp? Sorry for the n00bness
Offline
fg123 wrote:
Good idea.
For your code, displaying php variables would be like:
Code:
echo "<p>".$name."</p>"
Thanks. i'll work on it. I gtg soon
Wut more do i need to do on upload? Oh the button!
Last edited by ProgrammingFreak (2010-12-20 16:26:06)
Offline
You know, if you need any help with PHP, I'm willing to help out. Depending on what it is.
Offline
Did you guys work on scratch recourses together or something?
Offline
I agree that we should take him in. The more workers the faster it will be finished! of course I am not very good at HTML or PHP so I can't help.
Last edited by Pecola1 (2010-12-21 23:37:18)
Offline
I'm a he.
I could help with the "Approving" part probably, make it display the notes and other stuff in a text area and then you can change it, click approve, and it'll show up as that. Will we have a MySQL database, trust me, you/we/me will probably need it.
Last edited by Magnie (2010-12-20 20:28:21)
Offline
O_o A whole website for this?
Cool
Offline
Magnie wrote:
I'm a he.
I could help with the "Approving" part probably, make it display the notes and other stuff in a text area and then you can change it, click approve, and it'll show up as that. Will we have a MySQL database, trust me, you/we/me will probably need it.
![]()
ok, we first write the block to temp files in a temp directory were Magnie will make a script to read the temp files into a form were Sparks can approve the block and make changes. When Sparks clicks submit it will add it to the main SQL database. The data base should have the following collums (or whatever
) (3 database tables)
[SCRATCH BLOCKS]
- image path
- spec
- code
- user who submited it
- catagory (radio e.g. Motion)
[BYOB BLOCKS]
- final graphic image (path)
- graphic image of how to make it (path)
- sprite file (path)
- catagory
- name of submitter
[PANTHER BLOCKS]
- graphic image of block (path)
- block name
- selector
- colour
- catagory
- name of submitter
Hows that then Magnie?
Last edited by Daffy22 (2010-12-21 03:54:08)
Offline
Oh, ProgrammingFreak do you think it would be a good idea to have 3 button (or blocks
) that when clicked will show 3 different forms... Scratch, BYOB, Panther. Make sure you have a form element for each database colum above this post
Offline
Okay, Magnie here are the SQL details...
Name: blocklib_blocks
Host: 10.10.10.3
Username: blocklib_block
Password: library
Hows that
Offline
Hi guys, I thought I'd put a a few disgustingly bare html forms up - the peak of my HTML knowledge, so you can have a sort of idea as to how I picture the forms to work... if not look
Searching for a block
submitting a Panther block
submitting a scratch block
submitting a BYOB block
By no means are these set ideas, they're just an early representation and I think the contain all the necessary fields that the final ones will have! Feel free to make changes or disregard
Last edited by sparks (2010-12-21 05:56:13)
Offline