[QUOTE=Sc00by22;32759201]I like it, nice and clean.
As a customer, it would be cool to see my account credit somewhere on the page, I don't think it's displayed anywhere in the client area.[/QUOTE]
Good idea, I'll look into this (really depends on WHMCS's template setup, which is _TERRIBLE_ [as is most of WHMCS's setup]).
--edit:
having said that, it's definitely possible somewhere, but it might not be on the homepage/every page.
Use the jQuery library, it makes that code so much shorter
[code]if($('#input_html').val() == '') {
$('#output_html').text('HTML editor!');
}[/code]
[QUOTE=TehWhale;32761272]Use the jQuery library, it makes that code so much shorter
[code]if($('#input_html').val() == '') {
$('#output_html').text('HTML editor!');
}[/code][/QUOTE]
And it allows classes.
[QUOTE=zzlawlzz;32761295]And it allows classes.[/QUOTE]That is also very true
[QUOTE=TehWhale;32761272]Use the jQuery library, it makes that code so much shorter
[code]if($('#input_html').val() == '') {
$('#output_html').text('HTML editor!');
}[/code][/QUOTE]
what the hell are you doing? let him learn the real shit first
[QUOTE=zzlawlzz;32761248]I'm learning javascript.
[html]--snip--[/html][/QUOTE]
Store your DOM look ups, you're telling JavaScript to find the same thing twice, every time they press a key on the keyboard!
[php]
<script>
function html(el) {
// using "this" in the function parameter require no DOM look up
// if the value is null, set to an empty string
var html = el.value || '',
// this would be best as a global value so you don't keep looking
// up the DOM every second they type but that's up to you to learn :)
wysiwyg = document.getElementById('output_html');
wysiwyg.innerHTML = html;
}
</script>
</head>
<body>
<div id="output_html">HTML editor!</div>
<textarea id="input_html" rows="20" cols="50" onKeyUp="html(this)" placeholder="HTML Editor!"></textarea>
</body>
</html>
[/php]
HTML5 placeholder for the win. Btw, this isn't tested but it should work, I hope. :D
[QUOTE=TehWhale;32761272]Use the jQuery library, it makes that code so much shorter
[code]if($('#input_html').val() == '') {
$('#output_html').text('HTML editor!');
}[/code][/QUOTE]
Code is shorter but you have to load another file.
Got bored and made a navbar.
[quote]
[img]http://puu.sh/6WYY.png[/img]
[/quote]
Any opinions on where I should go with it?
Center it? Put a logo at the left? can't think of what to do.
[QUOTE=Adzter;32763769]Got bored and made a navbar.
Any opinions on where I should go with it?
Center it? Put a logo at the left? can't think of what to do.[/QUOTE]The texture for that really isn't good in my opinion. It also clashes with the background's scan lines.
Perhaps your links can be a little more inventive for starts. Why not look online for some inspiration? You can easily find lots of lists for stuff like that on the web.
[QUOTE=Adzter;32763769]Got bored and made a navbar.
Any opinions on where I should go with it?
Center it? Put a logo at the left? can't think of what to do.[/QUOTE]
Make the rest of the page. I don't really think that designing single elements is all that useful or that good of practice. Design is all about how everything fits together and you don't learn that at all by doing things like just making buttons or nav bars.
[QUOTE=Alcapwne;32746556]Just discovered this little gem:
[url]http://www.slaveryfootprint.org/[/url]
the way they've done the site is absolutely amazing! It's simple and classy but not boring or anything. The concept for the site is good as well,
check it out guys[/QUOTE]
Beautiful site, though the cause is optimistically fighting the "who gives a shit" stance, and on top of it, I feel uncomfortable disclosing all that bullshit hyper-accurate information on the site, even if it's locally computed.
How the fuck am I suppose to know if I have 14% veggies on my plate or not, who fucking calculates that shit?
[QUOTE=amcfaggot;32764670]How the fuck am I suppose to know if I have 14% veggies on my plate or not, who fucking calculates that shit?[/QUOTE][img]http://veggiemacabre.files.wordpress.com/2008/07/10101880adustin-hoffman-rain-man-posters.jpg[/img]
[php]
<script>
function clear() {
var html = document.getElementById('input_html'),
wysiwyg = document.getElementById('output_html');
wysiwyg.innerHTML = '';
html.innerHTML = '';
}
</script>
[/php]
What I doing wrong.
[QUOTE=zzlawlzz;32765720][php]
<script>
function clear() {
var html = document.getElementById('input_html'),
wysiwyg = document.getElementById('output_html');
wysiwyg.innerHTML = '';
html.innerHTML = '';
}
</script>
[/php]
What I doing wrong.[/QUOTE]
(I don't know javascript, so excuse me if this sounds stupid)
Don't you have to declare it like you did for html? Like
[code]
<script>
function clear() {
var html = document.getElementById('input_html'),
var wysiwyg = document.getElementById('output_html');
wysiwyg.innerHTML = '';
html.innerHTML = '';
}
</script>
[/code]
[QUOTE=zzlawlzz;32765720][php]
<script>
function clear() {
var html = document.getElementById('input_html'),
wysiwyg = document.getElementById('output_html');
wysiwyg.innerHTML = '';
html.innerHTML = '';
}
</script>
[/php]
What I doing wrong.[/QUOTE]Not using / using var on the variables in that function might be giving you some scope problems. You should also show the rest of the code though.
[QUOTE=TerabyteS_;32765908]Not using / using var on the variables in that function might be giving you some scope problems. You should also show the rest of the code though.[/QUOTE]
[php]<script>
function html(el) {
// using "this" in the function parameter require no DOM look up
// if the value is null, set to an empty string
var html = el.value || 'HTML editor!',
// this would be best as a global value so you don't keep looking
// up the DOM every second they type but that's up to you to learn :)
wysiwyg = document.getElementById('output_html');
wysiwyg.innerHTML = html;
function clear() {
var html = document.getElementById('input_html'),
wysiwyg = document.getElementById('output_html');
wysiwyg.innerHTML = 'HTML editor!';
html.innerHTML = '';
}
</script>
</head>
<body>
<div id="output_html">HTML editor!</div>
<textarea id="input_html" rows="5" cols="20" onKeyUp="html(this)" placeholder="Type HTML!"></textarea>
<br><br>
<input type="submit" OnClick="clear()" value="Clear">
</body>
</html>[/php]
[editline]13th October 2011[/editline]
[QUOTE=Jelly;32765899](I don't know javascript, so excuse me if this sounds stupid)
Don't you have to declare it like you did for html? Like
[code]
-snip-
[/code][/QUOTE]
nah, there is the ',' which makes the new var.
[QUOTE=zzlawlzz;32765941][php]<script>
function html(el) {
// using "this" in the function parameter require no DOM look up
// if the value is null, set to an empty string
var html = el.value || 'HTML editor!',
// this would be best as a global value so you don't keep looking
// up the DOM every second they type but that's up to you to learn :)
wysiwyg = document.getElementById('output_html');
wysiwyg.innerHTML = html;
function clear() {
var html = document.getElementById('input_html'),
wysiwyg = document.getElementById('output_html');
wysiwyg.innerHTML = 'HTML editor!';
html.innerHTML = '';
}
</script>
</head>
<body>
<div id="output_html">HTML editor!</div>
<textarea id="input_html" rows="5" cols="20" onKeyUp="html(this)" placeholder="Type HTML!"></textarea>
<br><br>
<input type="submit" OnClick="clear()" value="Clear">
</body>
</html>[/php]
[editline]13th October 2011[/editline]
nah, there is the ',' which makes the new var.[/QUOTE]
add "var wysiwyg;" right before the line with "function html(el)"
[QUOTE=TerabyteS_;32766061]add "var wysiwyg;" right before the line with "function html(el)"[/QUOTE]
why? that won't help at all.
[editline]13th October 2011[/editline]
the variable is defined IN the function.
[QUOTE=zzlawlzz;32766108]why? that won't help at all.
[editline]13th October 2011[/editline]
the variable is defined IN the function.[/QUOTE]
I think you should try that as well.
Your "html" function has no closing brace.
[editline]13th October 2011[/editline]
zzlawlzz , you should indent variables that are being declared with one var, otherwise it's very easy to assume it's global.
[QUOTE=jaybuz;32768006]Your "html" function has no closing brace.[/QUOTE]
sorry, copied and pasted wrong. There used to be something in the middle. I should have edited that when i add the brackets.
[editline]13th October 2011[/editline]
[url]http://stackoverflow.com/questions/7761398/textareadiv-wont-clear-onclick[/url]
Answered!
Who was building Gradstr and that other site?
Give me a message. I've been exploring the market and I've got some contacts at an investment firm who are interested in putting some VC into a project.
[QUOTE=adamjon858;32774091]Who was building Gradstr and that other site?
Give me a message. I've been exploring the market and I've got some contacts at an investment firm who are interested in putting some VC into a project.[/QUOTE]
[url=http://www.facepunch.com/members/218519-anton]anton[/url] was building grastr.
-snip-
[url]http://thinkvitamin.com/asides/carsonified-is-hiring-a-designer-80k-4-day-week-work-from-anywhere/[/url]
Worth a read.
[QUOTE=iamacyborg;32778303][url]http://thinkvitamin.com/asides/carsonified-is-hiring-a-designer-80k-4-day-week-work-from-anywhere/[/url]
Worth a read.[/QUOTE]That's one of the worst ways to find someone to hire. A lot of people are going to work their asses off for days to not even be considered and the company risks to hire someone who looks like he's good but he is not.
Going to rewrite/update the current sticky (Surviving FP WebDev), already got permission from a mod. On a side note, my [URL="http://www.reddit.com/user/imgur-mirror-bot/"]imgur-mirror-bot[/URL] surpassed 3000 karma after a week of operation, and over 1000 re-hosts.
[QUOTE=TerabyteS_;32778802]That's one of the worst ways to find someone to hire. A lot of people are going to work their asses off for days to not even be considered and the company risks to hire someone who looks like he's good but he is not.[/QUOTE]
You could spend the same amount of time writing cover letters and resumes and doing interviews really. Once I get to the point where I'm hiring people I'm not going to do it without seeing how well they are able to fill a brief.
[QUOTE=TerabyteS_;32778802]That's one of the worst ways to find someone to hire. A lot of people are going to work their asses off for days to not even be considered and the company risks to hire someone who looks like he's good but he is not.[/QUOTE]
Spec work is spec work. It has its positives and negatives.
In this case, I'd say it's mostly positive, as either way, you've produced something to show for your time.
Just coded up my first HTML email for work. What a fucking train wreck.
Sorry, you need to Log In to post a reply to this thread.