...

View Full Version : Sending Images as Variables



LivingShadow
01-25-2009, 09:55 PM
Well, I'm kind of new to Javascript. I was trying to do this in HTML, but I was pointed in the direction of Javascript.
I've found multiple examples of variable sending, but I can't seem to find one that I can easily change to send an image.
I've got image www.exampleimage.com/ex/image.png
I want to send from examplesite.com/page.htm to examplesite.com/page2.htm
I want to make the variable named AxeOfPrecision

This may be a simple thing in Javascript, I don't know, but all help is appreciated.

rnd me
01-26-2009, 01:01 AM
you can link to the image from both pages, not sure why you would need to transfer any image data...

LivingShadow
01-26-2009, 01:14 AM
What I want is to create a little virtual store. I'm starting small.
I want one image to be sent from my store page to the users item storage. At the moment, I'm just working with one page. Sending from one page to the second page. I'll go more complex (account-checking), later on.
So, by clicking example.com/item.png, I need it to go to myitems.com/storage.htm

jmrker
01-26-2009, 02:53 AM
In the HTML, try this:


<a href="myitems.com/storage.htm"><img src="example.com/item.png"></a>

May need to expand the URL to include http://www.

LivingShadow
01-26-2009, 02:56 AM
That will successfully take me to the page, I'm aware of that, but

I need it to go to myitems.com/storage.htm
I need the image to appear on the page.
Also, as long as I'm on the variable subject, how about creating a points system?
What variable approach would I take for that? With that one, I imagine I'll be able to figure out the recoding myself if you just point me in the right direction

LivingShadow
01-27-2009, 05:04 AM
Bump. I just want to make sure you don't forget about me (I apologize for the double post)
Okay, I got my points set up, but I do need a little help (probably a simple answer).
How do I raise/lower my variable by clicking an image? I want to keep the the page the same.

jmrker
01-27-2009, 05:17 AM
Bump. I just want to make sure you don't forget about me (I apologize for the double post)
Okay, I got my points set up, but I do need a little help (probably a simple answer).
How do I raise/lower my variable by clicking an image? I want to keep the the page the same.
:confused:
Post some code to comment on. No matter what we post will not solve your specific problem. Show what or where the problem is that you are asking about.

LivingShadow
01-27-2009, 05:36 AM
Sorry, I didn't realize that it would be confusing to understand.
So, I've got this variable points. Here's the code:


Points:
<script type="text/javascript">
var points = 0;
document.write(points);
</script>

Now, I want to raise the variable 10 in value by clicking an image. How would I code that?
Is that more clear?



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum