Hello everyone.
I've been browsing the web trying to find some help with coding. I'm starting a DC fan forum, and I would love to add a sort of hatchery to it. I would like to try something where members can enter the 4-digit code of their dragons, and then they would show up in either a specific area of the forum or perhaps within the global header in small, randomly selected groups. If that makes sense. However, I am a complete HTML, PHP, MySQL idiot (I've never touched the stuff) and the coding stuff just drives me batty. I was wondering if anyone knows where I could find a simple format that is free for editing for use, or could maybe walk me through making one of my own. Either one would be great.
Thanks a bunch!
Help with Coding
Moderator: General Moderators
- superdezign
- DevNet Master
- Posts: 4135
- Joined: Sat Jan 20, 2007 11:06 pm
Re: Help with Coding
That was... vague. lol
Firstly, what is DC?
Secondly, if these "dragons" are images that are stored online and these codes can be used to identify the images, then this is certainly possible. As a courtesy, you should copy the images to your website and load them from there rather than from the parent site, but that's your call. If you can provide us with the URL of an image and it's corresponding 4-digit code, or the means by which these dragons are defined, we can help you.
Programming is all about logic. Give us the logic, and we'll help you figure it out.
Firstly, what is DC?
Secondly, if these "dragons" are images that are stored online and these codes can be used to identify the images, then this is certainly possible. As a courtesy, you should copy the images to your website and load them from there rather than from the parent site, but that's your call. If you can provide us with the URL of an image and it's corresponding 4-digit code, or the means by which these dragons are defined, we can help you.
Programming is all about logic. Give us the logic, and we'll help you figure it out.
Re: Help with Coding
Oh, sorry, LOL!
DC is the abbreviation of a virtual dragon adoptable site called "Dragon Cave". There, members join and they get a "scroll", on this scroll they store their eggs and hatchlings, which require clicks and views/unique views to hatch and to grow into adults. The hatchery would be for eggs and hatchlings only. As for uploading the pics to my own site, I don't think that would work since each individual dragon is assigned its own unique 4-digit code upon creation. Though, it's entirely possible I'm not understanding you. I am new to this, this is my first time ever trying it ^__^;
I guess ... I hope that makes more sense?
DC is the abbreviation of a virtual dragon adoptable site called "Dragon Cave". There, members join and they get a "scroll", on this scroll they store their eggs and hatchlings, which require clicks and views/unique views to hatch and to grow into adults. The hatchery would be for eggs and hatchlings only. As for uploading the pics to my own site, I don't think that would work since each individual dragon is assigned its own unique 4-digit code upon creation. Though, it's entirely possible I'm not understanding you. I am new to this, this is my first time ever trying it ^__^;
I guess ... I hope that makes more sense?
- superdezign
- DevNet Master
- Posts: 4135
- Joined: Sat Jan 20, 2007 11:06 pm
Re: Help with Coding
Well, on the main site for this, are these dragons shown as images? Is it Flash-based? Is it Java-based?
Re: Help with Coding
They are images. Each type of dragon has it's own little sprite.
- superdezign
- DevNet Master
- Posts: 4135
- Joined: Sat Jan 20, 2007 11:06 pm
Re: Help with Coding
Alright then. Do you see the 4-digit code showing up the URL of either the sprite image or the page that the sprite image resides on?
Re: Help with Coding
Yes. Whenever you click on one of the sprites, it looks like this
http://dragcave.net/view/pHcC
the pHcC is what distinguishes that particular dragon from the others. I have a dragon who's 4-digit code is FART (and yes, in all caps just like that).
http://dragcave.net/view/pHcC
the pHcC is what distinguishes that particular dragon from the others. I have a dragon who's 4-digit code is FART (and yes, in all caps just like that).
- superdezign
- DevNet Master
- Posts: 4135
- Joined: Sat Jan 20, 2007 11:06 pm
Re: Help with Coding
Okay, then. In order to figure out their image, you have 2 steps:
Then you would save the file referenced by that src attribute on your site, and reference their sprite from there. They could have a button that they can click to tell your website to update their sprite. Instead of the button, you could automatically attempt to update it, but this would strain both your server and the main site's server. This could also possibly get your website blacklisted by their server, so I'd recommend against automatic updates.
- Get the HTML data from: http://dragcave.net/view/[b]4-digit-code[/b]
- Find the <img> element whose src attribute starts with "/images/"
Then you would save the file referenced by that src attribute on your site, and reference their sprite from there. They could have a button that they can click to tell your website to update their sprite. Instead of the button, you could automatically attempt to update it, but this would strain both your server and the main site's server. This could also possibly get your website blacklisted by their server, so I'd recommend against automatic updates.