Did the main site change???

User avatar
rubenwardy
Member
 
Posts: 4500
Joined: Tue Jun 12, 2012 18:11
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

by rubenwardy » Sat Dec 07, 2013 17:34

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.
 

User avatar
JMR
Member
 
Posts: 32
Joined: Sun May 19, 2013 11:31

by JMR » Sat Dec 07, 2013 17:45

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.
 

User avatar
rubenwardy
Member
 
Posts: 4500
Joined: Tue Jun 12, 2012 18:11
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

by rubenwardy » Sat Dec 07, 2013 19:10

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.
 

User avatar
webdesigner97
Member
 
Posts: 1307
Joined: Mon Jul 30, 2012 19:16
GitHub: webD97
IRC: webdesigner97
In-game: webdesigner97

by webdesigner97 » Sat Dec 07, 2013 19:39

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.

Lots of people do :D
 

User avatar
JMR
Member
 
Posts: 32
Joined: Sun May 19, 2013 11:31

by JMR » Sat Dec 07, 2013 20:45

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.


Well, can you important html/js? Surely one of us could write up javascript to do it, I could.
 

User avatar
Evergreen
Member
 
Posts: 2131
Joined: Sun Jan 06, 2013 01:22
GitHub: 4Evergreen4
IRC: EvergreenTree
In-game: Evergreen

by Evergreen » Sat Dec 07, 2013 21:26

JMR wrote:
webdesigner97 wrote:
rubenwardy wrote:
I know PHP too, I dont have access to the server, thats all.

Lots of people do :D


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.


Well, can you important html/js? Surely one of us could write up javascript to do it, I could.
Eh, I'm not against javascript in particular, but I know plenty of minetest people who are.
"Help! I searched for a mod but I couldn't find it!"
http://krock-works.16mb.com/MTstuff/modSearch.php
 

User avatar
JMR
Member
 
Posts: 32
Joined: Sun May 19, 2013 11:31

by JMR » Sun Dec 08, 2013 13:03

Evergreen wrote:
JMR wrote:
Well, can you important html/js? Surely one of us could write up javascript to do it, I could.
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....
Last edited by JMR on Sun Dec 08, 2013 13:05, edited 1 time in total.
 

User avatar
Evergreen
Member
 
Posts: 2131
Joined: Sun Jan 06, 2013 01:22
GitHub: 4Evergreen4
IRC: EvergreenTree
In-game: Evergreen

by Evergreen » Sun Dec 08, 2013 13:06

JMR wrote:
Evergreen wrote:
JMR wrote:
Well, can you important html/js? Surely one of us could write up javascript to do it, I could.
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....
Oh. In that case, go ahead. I'm not against it.
"Help! I searched for a mod but I couldn't find it!"
http://krock-works.16mb.com/MTstuff/modSearch.php
 

User avatar
JMR
Member
 
Posts: 32
Joined: Sun May 19, 2013 11:31

by JMR » Sun Dec 08, 2013 13:29

Evergreen wrote:
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....
Oh. In that case, go ahead. I'm not against it.



Easy. :-)

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
// 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]);


Pastebin: http://pastebin.com/gnKhfFiK

jsfiddle example(Refresh the page for a new quote): http://jsfiddle.net/aL2Qu/
Last edited by JMR on Sun Dec 08, 2013 13:39, edited 1 time in total.
 

User avatar
rubenwardy
Member
 
Posts: 4500
Joined: Tue Jun 12, 2012 18:11
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

by rubenwardy » Mon Dec 09, 2013 09:03

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]);


Did you mean to put that there?
Last edited by rubenwardy on Mon Dec 09, 2013 09:03, edited 1 time in total.
 

User avatar
JMR
Member
 
Posts: 32
Joined: Sun May 19, 2013 11:31

by JMR » Mon Dec 09, 2013 13:20

Did you mean to put that there?


I did, but was meant to remove it, it was for debugging purposes.
 

celeron55
Member
 
Posts: 430
Joined: Tue Apr 19, 2011 10:10

by celeron55 » Tue Dec 10, 2013 20:01

If people come up with multiple good quotes for that randomizer, I will add it there.
 

User avatar
sfan5
Member
 
Posts: 3636
Joined: Wed Aug 24, 2011 09:44
GitHub: sfan5
IRC: sfan5

by sfan5 » Tue Dec 10, 2013 20:30

What about this code:
http://jsfiddle.net/aL2Qu/3/
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
// [[<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>");
Last edited by sfan5 on Tue Dec 10, 2013 20:34, edited 1 time in total.
Mods: Mesecons | WorldEdit | Nuke
Minetest builds for Windows (32-bit & 64-bit)
 

User avatar
rubenwardy
Member
 
Posts: 4500
Joined: Tue Jun 12, 2012 18:11
GitHub: rubenwardy
IRC: rubenwardy
In-game: rubenwardy

by rubenwardy » Wed Dec 11, 2013 08:35

Why are you using 'jquery' rather than '$'?
 

User avatar
sfan5
Member
 
Posts: 3636
Joined: Wed Aug 24, 2011 09:44
GitHub: sfan5
IRC: sfan5

by sfan5 » Wed Dec 11, 2013 14:56

rubenwardy wrote:Why are you using 'jquery' rather than '$'?

I just copy-pasted that part from JMR's code
Mods: Mesecons | WorldEdit | Nuke
Minetest builds for Windows (32-bit & 64-bit)
 

User avatar
Novacain
Member
 
Posts: 285
Joined: Sat Aug 31, 2013 01:03

by Novacain » Wed Dec 11, 2013 23:55

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.


I personally like the "Radndom Bunch of Lunatics" it adds flavor. not to mention when you see it, you can't help but laugh. this is a game, not buisiness software. as for the quote, although I don't like the profanity, now it lacks sufficient flavor. there needs to be a little more description. is "crap-ton" too much for the main site?
Last edited by Novacain on Wed Dec 11, 2013 23:58, edited 1 time in total.
EXTERMINATE!!!
My Tronrealm modpack
My tronblocks mod
 

User avatar
mauvebic
Member
 
Posts: 1550
Joined: Fri Jan 27, 2012 11:32

by mauvebic » Thu Dec 12, 2013 03:35

GingerHunter797 wrote:Did the main site change???


No, We've always been at war with Eastasia.
"Fuck the hat." - Paulie Gualtieri
 

User avatar
hoodedice
Member
 
Posts: 1372
Joined: Sat Jul 06, 2013 06:33

by hoodedice » Thu Dec 12, 2013 08:12

mauvebic wrote:
GingerHunter797 wrote:Did the main site change???


No, We've always been at war with Eastasia.


ALL HAIL BIG BROTHER CELERON.
7:42 PM - Bauglio: I think if you go to staples you could steal firmware from a fax machine that would run better than win10 does on any platform
7:42 PM - Bauglio: so fudge the stable build
7:43 PM - Bauglio: get the staple build
 

User avatar
JMR
Member
 
Posts: 32
Joined: Sun May 19, 2013 11:31

by JMR » Fri Dec 13, 2013 18:47

rubenwardy wrote:Why are you using 'jquery' rather than '$'?


When using jquery on the mintest main page:
"DEPRECATED function call $(). Please use the jQuery() function instead. "
 

Previous

Return to Minetest General

Who is online

Users browsing this forum: No registered users and 12 guests

cron