rubenwardy wrote:I just removed the swearing.
I am not sure how to implement a random quote without PHP, I will leave that to c55 or Blockmen, if they want to do that.
JMR wrote:rubenwardy wrote:I just removed the swearing.
I am not sure how to implement a random quote without PHP, I will leave that to c55 or Blockmen, if they want to do that.
Great, thanks!
I'm experienced in PHP, I'd be happy to help with that if you like.
rubenwardy wrote:JMR wrote:rubenwardy wrote:I just removed the swearing.
I am not sure how to implement a random quote without PHP, I will leave that to c55 or Blockmen, if they want to do that.
Great, thanks!
I'm experienced in PHP, I'd be happy to help with that if you like.
I know PHP too, I dont have access to the server, thats all.
webdesigner97 wrote:rubenwardy wrote:JMR wrote:
Great, thanks!
I'm experienced in PHP, I'd be happy to help with that if you like.
I know PHP too, I dont have access to the server, thats all.
Lots of people do :D
rubenwardy wrote:JMR wrote:rubenwardy wrote:I just removed the swearing.
I am not sure how to implement a random quote without PHP, I will leave that to c55 or Blockmen, if they want to do that.
Great, thanks!
I'm experienced in PHP, I'd be happy to help with that if you like.
I know PHP too, I dont have access to the server, thats all.
Eh, I'm not against javascript in particular, but I know plenty of minetest people who are.JMR wrote:webdesigner97 wrote:rubenwardy wrote:
I know PHP too, I dont have access to the server, thats all.
Lots of people do :Drubenwardy wrote:JMR wrote:
Great, thanks!
I'm experienced in PHP, I'd be happy to help with that if you like.
I know PHP too, I dont have access to the server, thats all.
Well, can you important html/js? Surely one of us could write up javascript to do it, I could.
Evergreen wrote:Eh, I'm not against javascript in particular, but I know plenty of minetest people who are.JMR wrote:
Well, can you important html/js? Surely one of us could write up javascript to do it, I could.
Oh. In that case, go ahead. I'm not against it.JMR wrote:Evergreen wrote:Eh, I'm not against javascript in particular, but I know plenty of minetest people who are.JMR wrote:
Well, can you important html/js? Surely one of us could write up javascript to do it, I could.
This website itself uses javascript... Also the main website does already too....
Evergreen wrote:Oh. In that case, go ahead. I'm not against it.JMR wrote:Evergreen wrote:Eh, I'm not against javascript in particular, but I know plenty of minetest people who are.
This website itself uses javascript... Also the main website does already too....
// JMR's quote generator.
// You can include HTML within the quote.
// Add as many quotes as you would like.
var quotes=[
"I was flying around in my U.F.O. with a load of fuel in my inventory searching the deserts for pyramids. – The interesting part is: I found the pyramid half-buried in the sand!<cite><a href='https://forum.minetest.net/viewtopic.php?pid=111724#p111724' class='urlextern' title='https://forum.minetest.net/viewtopic.php?pid=111724#p111724' rel='nofollow'>Wuzzy</a>, <a href='https://forum.minetest.net/viewtopic.php?id=7063' class='urlextern' title='https://forum.minetest.net/viewtopic.php?id=7063' rel='nofollow'>Mod: Pyramids</a></cite>"
,"Some other quote"
,"Add as many as you'd like"
];
var random = Math.floor((Math.random()*quotes.length));random;
jQuery('blockquote > p').html(quotes[random]);
JMR wrote:// JMR's quote generator.
// You can include HTML within the quote.
// Add as many quotes as you would like.
var quotes=[
"I was flying around in my U.F.O. with a load of fuel in my inventory searching the deserts for pyramids. – The interesting part is: I found the pyramid half-buried in the sand!<cite><a href='https://forum.minetest.net/viewtopic.php?pid=111724#p111724' class='urlextern' title='https://forum.minetest.net/viewtopic.php?pid=111724#p111724' rel='nofollow'>Wuzzy</a>, <a href='https://forum.minetest.net/viewtopic.php?id=7063' class='urlextern' title='https://forum.minetest.net/viewtopic.php?id=7063' rel='nofollow'>Mod: Pyramids</a></cite>"
,"Some other quote"
,"Add as many as you'd like"
];
var random = Math.floor((Math.random()*quotes.length));random;
jQuery('blockquote > p').html(quotes[random]);
// [[<URL>|<TEXT>]] -> <a href='<URL>'><TEXT></a>
// [[<URL>]] -> <a href='<URL>'><URL></a>
var quotes = [
["I was flying around in my U.F.O. with a load of fuel in my inventory searching the deserts for pyramids. – The interesting part is: I found the pyramid half-buried in the sand!", "[[https://forum.minetest.net/viewtopic.php?pid=111724#p111724|Wuzzy]], [[https://forum.minetest.net/viewtopic.php?id=7063|Mod: Pyramids]]"],
["Some other quote", "someone"],
["Add as many as you'd like", "someone else"]
];
// Do not touch -- especially not the regexes in 's2html'
function s2html(txt) {
var r = [
[/\[\[([^|]*)\|([^\]]*)\]\]/, "<a href='$1' class='urlextern' title='$1' rel='nofollow'>$2</a>"],
[/\[\[([^\]]*)\]\]/, "<a href='$1' class='urlextern' title='$1' rel='nofollow'>$1</a>"]
];
for(var i = 0; i < r.length; i++) {
while(r[i][0].exec(txt) !== null)
txt = txt.replace(r[i][0], r[i][1]);
}
return txt;
}
var random = Math.floor((Math.random()*quotes.length));
jQuery('blockquote > p').html(s2html(quotes[random][0]) + "<cite>" + s2html(quotes[random][1]) + "</cite>");
rubenwardy wrote:Why are you using 'jquery' rather than '$'?
JMR wrote:I don't think the "Flying around in a UFO" quote is suitable. It did put me off a bit. Maybe consider using another one? ;) Also the text "Minetest is developed by a random bunch of lunatics." isn't very appealing, although it may be true, maybe word it differently. "Minetest is developed by a random group of developers who have a passion for games"?
I prefer a more clean look on a website, but I think the minetest website could do with being more responsive. I am also a web designer and responsive web design is getting more crucial.
GingerHunter797 wrote:Did the main site change???
mauvebic wrote:GingerHunter797 wrote:Did the main site change???
No, We've always been at war with Eastasia.
rubenwardy wrote:Why are you using 'jquery' rather than '$'?
Users browsing this forum: No registered users and 12 guests