Troy III 272 Posting Pro

@hamid, No Hamid that's not true.
I was there when quotes were introduced in HTML for the first time in history of the web. They were introduced as allowed means of expressing values which contain "word-break characters".
Meaning, not only they are neither mandatory nor required, they are allowed to be used in a naming tentative which would otherwise break in two or more tokens in case that it required a wbr char.
So, no. Quotes are not required to keep the token in one peace when there are no word breaking characters present. And because this is HTML, not xhtml.

Troy III 272 Posting Pro

How about you post a fiddle intead?

rproffitt commented: Fiddles are nice. +10
jonsan32 commented: Agreed. Sorry. I kinda suck at this :-) +3
Troy III 272 Posting Pro

how many images?
1. say, will they be like 2 alternating images sequencing two hours intervals.
2. every two hours in a day a new image (that makes 12 in total) to be shown as hours pass.
3. fixed in client time of application use, or in UTC Time of a local user?

how would you expect anyoe to be able to respond correctly if there are so many modalities involved, could you?

Troy III 272 Posting Pro

Of course not. It is never OK to use the same ID for two or more individual subjects in the same global context. But ain't that obvious?

Troy III 272 Posting Pro

AleMonteiro says:
"As I understand it, the purpose of the closure when defining the object is just about code organization and keeping some desired functions hidden from the global context."

Thanks for revealing that this thread is not about prototypal inheritance -nevermind its Title: "Prototypal Inheritance" - but something completely different, namely: cosures.

My wrong I guess. :)

Troy III 272 Posting Pro

I don't think I para-like it. In fact, I think I para-hate it.
Or it's just that I'm simply growing old?er.

Troy III 272 Posting Pro

as already stated - it's a self defeating aim and purpose.

People need to learn to respect LiveScript for what it is;
in order be able to learn how it is.

And in general, probably stop demanding rigid behavior expected from old static procedural languages.

Animal is a >>generic<< object
"Cats" and "Dogs" are >>specific<< objects.

Therefore, (for our own benefit) we can, and we should use Generic Objects to easily create specific [animals] - not the other way around, nor completely misunderstand the point of inheritance.

Troy III 272 Posting Pro

AleMonteiro says:
"Troy, I may be wrong, but I think Dave was only trying to wrap all of Cat's code inside the Cat function."

But than, why would he need "Animal"?

Troy III 272 Posting Pro

Uninstall that damn wormhole

Troy III 272 Posting Pro

it was the malformed HTML and the douped form id...

Troy III 272 Posting Pro

@hpox
1.what were you doing before things started going south?
2.did you visit a site requesting you to install JAVA engine?
3.what is your current OS?

Troy III 272 Posting Pro

DaveAmour says:
(is there) "a way of getting the code which makes Cat inherit Animal actually inside the Cat function".

But that - my friend - (in case I understand your sentence well) is a request of a self defeating puropse.

Wouldn't it, than, require a Dog to define the Animal inside a Dog all over again?[!]

Could you please clarify, or better emphasize on: what are you after, or what would be the aim of it?

Regards.

Troy III 272 Posting Pro

I always thought that JavaScript is the only language that has the potential of producing a live, living & evolving A.I.

Troy III 272 Posting Pro

There are other critical uses also.

Say, checking for an explicit "undefined" value of a named property.
Checking if a variable name is already declared but (still) not initialized.
Or, that there is an object member whose value is still waiting to be assigned a value etc.

Troy III 272 Posting Pro

maybe this way you will have a better overview of your error in variables "salate" & "suppen":

var pizzen = 
    [
        ["Mageritha", 4.90],
        ["Cardinale", 5.90],
        ["Salami", 6.90]
    ];

var salate = 
    [
        ["Insalata Mista", 3.5],
        ["Insalata Polo", 5],
        ["Insalata Tonno", 5.5]
    ];
var suppen = 
    [
        ["Tomatencremesuppe", 2.8],
        ["Knoblauchcremesuppe", 2.9],
        ["Frittatensuppe", 3]
    ];

watch out the oppening and closing of inner array literals.

Troy III 272 Posting Pro

@SimonIoa, you are still late! Because once again you refuse to mark the thread as solved.
Secondly
You say "because (you've found) the solution days before"

Yet, everybody can see that your question was posted:
4 days ago;
and that my solution (to your problem- not mine) was also given:
4 days ago!

Meaning, exactly the same day you've asked the question. So…, people may be scratching their heads while asking:
How is it that you've found the solution days before even having the problem?

Ain't that the most ridiculous lie you've ever heard?

And...
No, SimonIoa - I said "that our vast community would be benefiting a lot more from marking helpful posts and solutions for what they are"
That is: SOLVED! Because you didn't, and I asked - why?

p.s.:
And you still haven't!

Troy III 272 Posting Pro

SimonIoa, thanks for the endorsements and all but I think that our vast community would be benefiting a lot more from marking helpful posts and solutions for what they are, because you didn't, - why?!

Troy III 272 Posting Pro

dt1.match(/\S+/g).join('');
_> "11:30:am"

Troy III 272 Posting Pro

The lowsrc has been used to load a low-resolution copy of the original image before the full resolution src-image has been loaded.

Now...
- Would you like to know why?

Troy III 272 Posting Pro

You have a wrong understanding on the case here, because there's no other call and no wild card selector! You are simply obtaining a reference to an allready existing DOM colection Object. And once you get hold of it - and you can obtain it long before any page elements have been parsed, there's no possible sweat going on there.

You can, however, do all kind of tests to see if it's faster invoking a custom JavaScript function; do all if and else's in a row and return the match for every single turn you have to reference an element, only to confirm that a simple element picking is the fastest possible method. And it's no brainer in comprehending that: simply picking the required element from the hash without any processing, is by orders of magnitude faster than any other.

It's as fast as myobj[prop] call that nothing can compete with. Not even a pure "document.getElementById" method. Especially not a syntax that needs to:

  1. locate function object;
  2. pas an argument;
  3. process its value for request identification in several steps;
    3.1. invoke the built-in getElementById function;
    3.2. which in turn, once again needs to call and get hold of "document" element;
    3.3. which owns the "getElementById" function;
    3.4 and is (also)a window property;
    3.5. of the same level as any other element with an ID.

Which means that "_.myElement" syntax is as fast as calling for "window.document"!

Regards.
p.s.:
With HTML5 back …

Troy III 272 Posting Pro

...and here is a fiddle http://jsfiddle.net/qyu9q09v/
is this how they used to look?

Troy III 272 Posting Pro

<a> is not an Anchor Element without a properly initialized href object.
It's the same as if you've written:

_> <z><img.../></z>

so it will inherit from HTMLUnknownElement Prototype.

But, your real problem is the <img> tags being nested into <a> elements.
Which are inline elements; have no layout; and no position in document flow.

Your css targeting images, which are relative. But relative to what?

So to cut the story short, [this] quick tweak of your existing css, will restore the presentation to its previous state:

.poster a img{ width:100%; height:100% }
.poster a { display: inline-block; }
.poster {
    width:25%;
    height:25%;
    position:absolute;
    margin-left:20px;
    z-index:0;
}
    .poster a,.poster img {
        -moz-border-radius: 50%;
        -webkit-border-radius: 50%;
        border-radius: 50%;
        height:55px; width:55px
    }
    .poster a:nth-child(1) {

        position:relative;
        bottom: -57%; left: 33%;
    }
    .poster a:nth-child(2) {

        position:relative;
        bottom: -15%; right:-6%;
    }
    .poster a:nth-child(3) {

        position:relative;
        bottom: 18%; left: 10%;
    }
    .poster a:nth-child(4) {

        position:relative;
        top: 10%; right: -17%;
    }
    .poster a:nth-child(5) {

        position:relative;
        top: 55%; right: 7%;
    }
    .poster a:nth-child(6) {

        position:relative;
        top: -20%; right: -40%;
        height:100px;
        width:100px

    }
Troy III 272 Posting Pro

To tell you the truth, I dont have any jQuery skills - and since the main reason of using it, was W3C's blunt of introducing the lamest ever

var myElement = document.getElementById("myElement");

severe coder-hostile syntax, with something like $("myElement") function, - I never bothered using it (for it was heavy and slow and somewhat uglier than conventional myElement call), since I already had my own super lightweight solution, which I overcame with a simple one-liner like:

var _ = document.all || document.getElementsByTagName("*");

placed on the document head or anywhere on the script, wherein a lot faster and cleaner syntax like this was possible:

_.myElement

which also made it possible of accessing broken token id's like id="my element", with:

_['my element']

syntax, without calling a function to do that.

and it was easier to refresh and re-enable old coded pages with myElement calling syntax (which were rendered obsolete and dysfunctional by this W3C assault), using _. prefix than anything else.

And it still is.

Now to answer your question:
That's where we are targeting/referencing the text-node we are about to replace, without disturbing the environment of its nest. With a similar technique supported by advanced HTML5 and old versions of IE.

As you can see the "theme-my-login1" previous sibling is exactly the text-node we want to change with a standard well supported DOM.replaceChild syntax.

Regards.

Troy III 272 Posting Pro

Bump!
( serious coders have been sufferning for this for decades. Now that it's here it seems as if they've got used to getting a painful path around, accepting the fact that it doesn't exist. )

Troy III 272 Posting Pro

@Sofersurfa
You should never, ever, assign the same ID to two or more subjects within the same popullation. This act in direct violation with the very definition of ID, its core purpose and meaning.

Troy III 272 Posting Pro

But off course you saw it (it's not invisible) yet overlooked it with pride like, something that could never, ever, even have a chance to work.
But it does! Perfectly, despite the firsthand unexpected and unpredictable underestimating prejudice. And of course it is edgy but on the better side of its meaning. Which is termed - advanced!

Troy III 272 Posting Pro

@ diafol: Why this has been overlooked so far I don't know

that solution is so edgy they were afraid to even look at it!

Troy III 272 Posting Pro

mattyd
you've changed the width of your form container - or you'vechanged the font or size; anything of that kind - or simply added borders, -just ad some more space to elements in the container and it will come back to normal.

p.s.: next time avoid using floats for the given purpose, as you can see they will let you down with a big question mark above your head.

mattyd commented: Worked. Thank you! +8
Troy III 272 Posting Pro

JavaScript

<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8>
</head>

<body>

<div class="wpb_wrapper">
    Log In
    <div class="login" id="theme-my-login1">
      This text doesn't change
    </div>
</div>


<script>

    this['theme-my-login1'].parentElement.replaceChild
    (   document.createTextNode("Don't Login!"), 
        this["theme-my-login1"].previousSibling 
    );

</script>

</body>
</html>
diafol commented: Why this has been overlooked so far I don't know +15
JorgeM commented: Javascript master +12
Troy III 272 Posting Pro

This shouldn't have worked on either. It's a Mozilla faulty omission for allowing the add of arbirary style property names (and values) as strings [!!!]
document.getElementById("list_bogor_2014_2015").style = "display:none";

Troy III 272 Posting Pro

you are calling the property "k" of object "f" which is "undefined" at line 32 col 244.
Make sure "f" points to the object containing "k" property before calling it.

Troy III 272 Posting Pro

"oh my god" - where am I?!!
panjiasmara, you never told us how did you call the function "showDiv()" in your original script.

Please do, because if it worked on other systems we can make it work on apple too.

Troy III 272 Posting Pro

What do you need the ID's of the images for?

Troy III 272 Posting Pro
Determine if a namespace/variable-name exists
Check for namespace existence in your environment variables and objects before writing to them.

Guess if "Book1.chapter22.paragraph37" exists without provoking errors and retrieve/send data if it exists with simplest JS expressions.

Call syntax:

isNS( [string], [num] );

Example:

 var nsresult =
 isNS( "Book1.chapter22.paragraph37", -1 ); 
 if( nsresult[0] ){ send( nsresult[1] ) else notify( nsresult[4], nsresult[2] ) };...

etc, etc.

Omit secondary argument (function-return modifier) to get a Boolean.
(Using 0, false, or undefined keyword has the same effect.)

 isNS( "myObject.property.subProperty.myMethod" );

_> Boolean : true/false

Modifier Possible values:
_> -1; (0|false|undefined); ( 1|true ); 2; 3 or 4.

Description:
(-1 ) _> returns array object containing complete inoculation.
( 0 ) _> optional; returns Boolean: true (if complete NS chain exist) : false (if it's broken).
( 1 ) _> if NS query exists, case true: returns the existing value; if not, case false: returns the last valid context if any, or the global object if root doesn't exist.
( 2 ) _> returns an array of existing namespaces in the argument query.
( 3 ) _> returns an array containing all specified namespaces.
( 4 ) _> returns the original query string.

*NS - stands for already familiar "Namespace" initials.
[This makes but a tinny cluster on some real A.I., Yet -a very important one!]

Troy III 272 Posting Pro

Not specify the (container) div height.

Troy III 272 Posting Pro

What can I do to the column variable has the Date value, for example?

It's rather -what do 'you' want to do with them?

Troy III 272 Posting Pro

if (/(\d{4})-(\d{2})-(\d{2}) (\d{2}):(\d{2}):(\d{2})/.test(list[i].?))

What's the dot + questionmark doing there?
Remove that, and come again.

Troy III 272 Posting Pro

What is the HTML structure containing those inputs?
And what doc-type are you using?

Did you change any of the above-mentioned before this issue has arisen?

Troy III 272 Posting Pro

z-index:0;
is equivalent to: unspecified / invalid / value failed to be assigned, etc, etc.

div1 > z-index:0 -will be covered by
div2 > [no index specified]

almostbob commented: 0 <> unspecified -3
Troy III 272 Posting Pro

The case in question is about obtaining a horse first, than - if you like - you may also beat it.

Troy III 272 Posting Pro

That page should be run on IE - after running it you should get a safety warning msgBox : hit YES than check in "C:/" and get "test.txt" file for your hello message. It will be there.

Troy III 272 Posting Pro

even W3schools got this right:

"Note: z-index only works on positioned elements (position:absolute, position:relative, or position:fixed)."

[!note] Your z-index:2 div element has no position.

Further on, "z-index: 0", (used on your second div) is not a valid z-index css value. Should be a non-zero positive integer or negative. Not sure if you can find this inf., in css documentation though.

almostbob commented: wrong -3
Troy III 272 Posting Pro

The problem is that people dont reach pages to be getting some awesomness unless the awesomnes is a part of your page >>content<< not the design.

A good rotator is the one that makes it easy for you to have an immediate overview of your service or information contained in that domain allowing you a hyper-jump to the section site service or info you are really interested in.

Anyway, I came to tell you that from trying to visit https://behance.net I get:

Your connection is not private
Attackers might be trying to steal your information from behance.net (for example, passwords, messages, or credit cards).

This server could not prove that it is behance.net; its security certificate is from *.behance.net. This may be caused by a misconfiguration or an attacker intercepting your connection.

diafol commented: Good points +15
almostbob commented: way too many go for form, without function, goodonya +13
Troy III 272 Posting Pro

Just wanted to know from Daniweb expert! Which is more useful and suitable on home page? Rotating slider or static banner.

The most useful thing on your page is the information a client came in for to be immediately reachable, highly accessible, prominently visible, very intelligible.

Meaning Neither.
Banners are the least and the last thing that your client will or will not appreciate on your page; my page; any page.

Troy III 272 Posting Pro

:) That's because in JavaScript everything is variable.

Prefixing a variable-name [initially] containing a String (object or literal) with $ symbol - is plain dumb, for who knows what it may become few lines after.

Furthermore JavaScript is a Dynamic Types language, treating it as Static is simply wrong.
A plain literal string depending on a stituation may change its type from string to any other js-type, and that's a beauty of it, it's Alive!

Troy III 272 Posting Pro

Not really. You see, prefixing string-variable names with a certain symbol like $, is not all that bad...
Seeing my uncle do that, would feel quite normal to me. -He is from '70-ties!

But this is JavaScript. :)

Troy III 272 Posting Pro

Ace editor!
What's that?

Troy III 272 Posting Pro

the difference between var $name and var name is that whenever you see a person using $name in his code instead of normal name, avoid talking to him, avoid conversing with him, avoid WORKING with him, and if your girlfriend happens to know him drop her too, even if he's family. Otherwise take on him and make him your slave, the only thing they are good for, anyway :)

Troy III 272 Posting Pro
   function keyListener(e) {
      e = e || event; 
      if (e.keyCode==37 && basketLeft > 0) {
      ...
Troy III 272 Posting Pro

You make a Google search and want to make some notes on the content of that page, save them and send them to me so I can also make notes on your notes.

google is protected, you can't make notes on google-page search-results, because you cant host it in your environment.