• Web Development Questions That Don't Need Their Own Thread v2
    3,079 replies, posted
[QUOTE=Ac!dL3ak;32754592]Just a thought, why is flash something you want to avoid when developing a website? I know I shouldn't, I just don't know why.[/QUOTE]I feel like the biggest reason is mobile considerations.
[QUOTE=zzlawlzz;32752576]The group hide isnt just for html you can just select a line of code and hide it They dont even need to be the same group.[/QUOTE] Who said it was just for HTML?
[QUOTE=Ac!dL3ak;32754592]Just a thought, why is flash something you want to avoid when developing a website? I know I shouldn't, I just don't know why.[/QUOTE] It depends on what you're using it for, if it's a game then that's fine, but if you're using Flash to implement a menu or such it should probably be rethought. Back when the web stagnated (thanks MS!), people used Flash for everything (hover effects for menus, scrollable text boxes, etc.), back then it kinda made sense, but if you do it now it just shows you're a bad developer (I know a guy who does it, quite strange to see the justifications, one was that Flash "rendered text")
I was bored so I made this real simple HTML editor. [t]http://i.imgur.com/2LXGn.png[/t] Oldschool, no syntax highlighting cause I dont have the knowhow. I know that <BODY> is missing but I'm not going to bother with another screenshot to fix that, I had some other stuff int here to test if it all came out correctly and deleted it to put the "Hi Facepunch" in. I deleted too far.
[QUOTE=reevezy67;32755403]I was bored so I made this real simple HTML editor. [t]http://i.imgur.com/2LXGn.png[/t] Oldschool, no syntax highlighting cause I dont have the knowhow. I know that <BODY> is missing but I'm not going to bother with another screenshot to fix that, I had some other stuff int here to test if it all came out correctly and deleted it to put the "Hi Facepunch" in. I deleted too far.[/QUOTE] As cool as that is, creating it with HTML and JavaScript would have been the smart move. :P Then anyone on the internet can use it. HTML editor web app!
[QUOTE=jaybuz;32755465]As cool as that is, creating it with HTML and JavaScript would have been the smart move. :P Then anyone on the internet can use it. HTML editor web app![/QUOTE] I know nothing about JavaScript, I only know some HTML because of browser integration into C# I thought it may be useful. This only took me a few minutes to whip up.
[QUOTE=reevezy67;32755594]I know nothing about JavaScript, I only know some HTML because of browser integration into C# I thought it may be useful. This only took me a few minutes to whip up.[/QUOTE] It's probably better than Dream Weaver anyway.
hello. should this work? [code] #content p:first-child:first-letter { float:left; font-size:1.6em; } [/code] it doesn't. #content p and #content p:first-letter work
[QUOTE=Cuel;32760545]hello. should this work? [code] #content p:first-child:first-letter { float:left; font-size:1.6em; } [/code] it doesn't. #content p and #content p:first-letter work[/QUOTE] [img]http://dl.dropbox.com/u/5483751/Photos/2011-10-13_1752_001.png[/img] It does work. I changed float: left to float: right here so it is clearer.
what the hell. it works on #content h2:first-child:first-letter but not on p. can't figure this one out
[QUOTE=Cuel;32761306]what the hell. it works on #content h2:first-child:first-letter but not on p. can't figure this one out[/QUOTE] What are you trying to do?
a drop cap. i could just use a class on the first letter but this should work and i want it to work
How would I go about doing an overflow:scroll on this window? JavaScript is not really my thing [code] function openwindow() { window.open("bidraget.html","mywindow","width=400,height=500"); }[/code] Edit: fixed it [code] function openwindow() { window.open("bidraget.html","mywindow","width=400,height=500, scrollbars=1"); }[/code]
[QUOTE=Cuel;32761384]a drop cap. i could just use a class on the first letter but this should work and i want it to work[/QUOTE] Try it without the float: left, if that doesn't work, use this example: [url]http://jontangerine.com/silo/typography/p/[/url]
[QUOTE=mobrockers2;32761630]Try it without the float: left, if that doesn't work, use this example: [url]http://jontangerine.com/silo/typography/p/[/url][/QUOTE] yup that one worked, thanks.
Guys how would you suggest making a website? I am beginner but was wondering if there are some kind of ways to build general backbone (like design) which would automatically rescale. Atm I have temporary page: [url]www.bshc1.info[/url] But on different resolutions it fucks up. on 1920x1080 it's fine but on others, it's crap. Any ideas?
[img]http://i.imgur.com/M4UTT.png[/img] __ Chrome | Firefox __ WHY :pwn:
I just started using PHP and MySQL, but what does [code]Warning: mysql_fetch_assoc() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\website\tekstur.php on line 14[/code] mean?
[QUOTE=Persious;32779290]I just started using PHP and MySQL, but what does [code]Warning: mysql_fetch_assoc() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\website\tekstur.php on line 14[/code] mean?[/QUOTE] posting your source code would help. [editline]14th October 2011[/editline] or, if stinky releases his php error :dance:
[QUOTE=Persious;32779290]I just started using PHP and MySQL, but what does [code]Warning: mysql_fetch_assoc() expects parameter 1 to be resource, boolean given in C:\xampp\htdocs\website\tekstur.php on line 14[/code] mean?[/QUOTE] The official PHP documentation is usually your answer to these problems. You're trying to fetch the result of a [b]mysql_query[/b] call: [url]http://php.net/manual/en/function.mysql-query.php[/url] It will only return a resource IF the query is successful, otherwise you get a fat ugly boolean type, [b]false[/b], which is not a valid parameter for [b]mysql_fetch_assoc()[/b] tl;dr: your SQL query is incorrect.
Nevermind, I did something dumb C: It's fixed now.
I want to make a directory site. I've never done so before. I have a good domain name in mind (it's available but not bought yet) I'm thinking I should build a site list by waiting/asking for submits to the list, i then approve which sites get passed in and which don't [I][B]Is that a good idea?[/B][/I] I want to make this directory site because it can pay for itself and I want something on my resume. -------------------------------- is this a good idea? basically a site where you enter a topic you'd like to talk about and your email address. then someone else sees the topic puts in their email and their response. you receive their response by email, but it's from the site's email, no the other person. In the email there is a link that you use to respond. Like anonymous emailing with strangers
What kind of directory are you talking about? Most are essentially worthless.
[QUOTE=Sprite;32779772] is this a good idea? basically a site where you enter a topic you'd like to talk about and your email address. then someone else sees the topic puts in their email and their response. you receive their response by email, but it's from the site's email, no the other person. In the email there is a link that you use to respond. Like anonymous emailing with strangers[/QUOTE] great idea! 4chan would be a good name for that sort of thing also regarding the directory, why would a) companies want to be on your site, and b) people go on your site?
-snip- i read it wrong.
I have some basic PHP code for listing a directory with a blacklist, but how would I go about making it also make it so that you can click the outputted links and they lead to the appropriate directory. Heres what I've got so far [php] <?php if ($handle = opendir('.')) { $blacklist = array('.', '..', 'css', 'projects.php', 'lol.jpg', 'wordpress', 'Thumbs.db', 'index.php', 'images'); while (false !== ($file = readdir($handle))) { if (!in_array($file, $blacklist)) { echo "|&nbsp;&nbsp;&nbsp;$file&nbsp;&nbsp;&nbsp;|"; } } } ?> [/php] Appologies if that's awful PHP code I'm still learning. The only thing I thought of was doing this: [php] echo "<a href="$file">|&nbsp;&nbsp;&nbsp;$file&nbsp;&nbsp;&nbsp;|</a>"; [/php] Which just threw out an error as I expected
[QUOTE=Adzter;32785940]I have some basic PHP code for listing a directory with a blacklist, but how would I go about making it also make it so that you can click the outputted links and they lead to the appropriate directory. Heres what I've got so far [php] <?php if ($handle = opendir('.')) { $blacklist = array('.', '..', 'css', 'projects.php', 'lol.jpg', 'wordpress', 'Thumbs.db', 'index.php', 'images'); while (false !== ($file = readdir($handle))) { if (!in_array($file, $blacklist)) { echo "|***$file***|"; } } } ?> [/php] Appologies if that's awful PHP code I'm still learning. The only thing I thought of was doing this: [php] echo "<a href="$file">|***$file***|</a>"; [/php] Which just threw out an error as I expected[/QUOTE] use a foreach loop
[php] <?php $blacklist = array('.', '..', 'css', 'projects.php', 'lol.jpg', 'wordpress', 'Thumbs.db', 'index.php', 'images'); foreach(scandir('.') as $file){ if(!in_array($file, $blacklist)) echo $file; } [/php] It irks me to see people do something with lots of functions when you could simplify it a lot and just use one function and less lines.
The SPL also has a bunch of useful iterators for that sort of stuff, for example, [url=http://php.net/manual/en/class.directoryiterator.php]DirectoryIterator[/url].
I have a question, is there any software, or code that i could use so that i could stream music from my site to the internet but still have a folder on my computer that would allow me to play music off my computer but also have it online so other people could hear it?
Sorry, you need to Log In to post a reply to this thread.