I have taken code off the internet that I found: http://wserver.co.uk/ringoffire.php
its an online ring of fire game, very good.
anyways I wanted to amend it, and even make my own game eventually from the code.
I have been able to style the HTML using CSS but I haven't managed to change the size of the icons for the cards:
suits = [
["♥", "#FF0000"],
["♦", "#FF0000"],
["♣", "#000"],
["♠", "#000"]
];
$('#selection').html("<span style='color:" + suits[suit][1] + "'>" + numbers[number][0] + suits[suit][0] + "</span>");
$('#chosen').html("<span style='color:" + suits[suit][1] + "'>" + numbers[number][0] + suits[suit][0] + "</span> " + $('#chosen').html());
$('#meaning').html(numbers[number][1]);
chosencards.push(number + "" + suit);
if(numbers[number][0] == '5' || numbers[number][0] == 'K'){
$('#rules').html($('#rules').html() + "+ " + prompt("Please enter a rule") + "<br />");
Now I am just learning Javascript and CSS (I'm 29!) but I have tried my darndest to change the size of the icons. I see that the span color style is refering to the suits variable but what ever I tried just doesn't work,I tried putting them in divs relevent to the elements but that didn't work, I even tried to put a ahref tag around them to see if I could style it that way but no go.
so how do I set the size of the icons?
thanks in advance!

New Topic/Question
Reply



MultiQuote




|