Welcome To Snipplr


Everyone's Recent Snippets Tagged javascript



« Prev 1 2 3 4 5 ... 46
<p><div id="calc"> <p><b>VAT rate:</b> <input type="text" id="vat_rate" placeholder="20" size="10" value> <p><b>Net price:</b> <input type="text" id="net_price" size="10" value> <p><b>Gross price:</b> <input type="text" id="gross_price" size="1...
0 16168 posted 5 years ago by antonykidless
This code is used to get the unique values of an array.
0 16099 posted 5 years ago by jlustre
To display events from The Events Calendar Pro organized by taxonomy
0 13580 posted 5 years ago by reflectiondigital
JavaScript is a client-side as well as server side scripting language that can be inserted into HTML pages and is understood by web browsers. JavaScript is also an Object based Programming language. Example Note: This is an example, you can change...
0 13550 posted 5 years ago by priyagchaudhary
Typoscript fields are not exported by default in Powermail. If you want them to be exported you need to add this line in the Page TSConfig of your root page or form page:
0 12477 posted 5 years ago by xtine777
Add values from a given field in your database
1 12702 posted 5 years ago by xtine777
With this snippet you will have the ability to deliver the most recent version of any file. When dealing with a browser's cache you can't be certain your viewers are getting the most recent copy. By appending a GET value (the UNIX timestamp) to, f...
0 12160 posted 5 years ago by daemondevin
Funktioniert auch in Partials etc... Z.B.: bootstrap_package/Resources/Private/Partials/Page/Navigation/Main.html
0 1373 posted 5 years ago by xtine777
Debugging in Controller and Fluid Template
0 1393 posted 6 years ago by xtine777
In typo3conf/ext/extensionname/Configuration/TCA/Overrides/tt_content.php oder in ext_tables.php
0 1341 posted 6 years ago by xtine777
Bei der Entwicklung einer eigenen Extension muss folgendes bedacht werden: ab TYPO3 Version 7 überschreibt die Deklaration von plugin.tx_extensionname.persistence.storagePid den Wert im Feld "Datensatzsammlung". Dazu muss nicht einmal ein Wert für st...
0 1619 posted 6 years ago by xtine777
Typoscript for multilevel vertical menu, expanding when clicked
0 1230 posted 6 years ago by xtine777
Show meaningful error messages in frontend
0 1281 posted 6 years ago by xtine777
rightColumn = COA rightColumn.2 < styles.content.get rightColumn.2.select.where = colPos=2 rightColumn.2.slide = -1
0 1604 posted 6 years ago by xtine777
JavaScript regex for validating IP addresses, has been tested!
0 1284 posted 7 years ago by plasticbottle
It should work for domains like @something.co.uk note that regex will never really be able to match 100% of e-mail addresses without allowing some false positives
0 1242 posted 7 years ago by plasticbottle
This was an assignment given to me in my Java course.
0 2682 posted 7 years ago by EthanEC94
Hide parent element, when child element has a specific class. In this case: child element = .no-news-found parent element = .csc-default (= content element containing the news plugin with header)
0 1237 posted 7 years ago by xtine777
This snippet code allows you to prevent the viewer from being able to right-click on your page. This can discourage the average user from borrow images or code from your site.
0 1378 posted 8 years ago by apphp-snippets
A one-liner that converts a decimal number to a binary number
0 1336 posted 8 years ago by rm1984
How to pass a parameter into a method from an onClick method found in the render method. Majority of the times when you need to do this, your adding it through a loop. In this case, call a function where the item in the loop will automatically be...
0 1436 posted 8 years ago by heathbo
ResponsiveBootstrapToolkit : https://github.com/maciej-gurban/responsive-bootstrap-toolkit
0 1200 posted 9 years ago by dhjapan
Use ref with getDOMNode() to get the actual html. Using getBoundingClientRect() on the actual html will give you the width, height, etc. Below: specs = ClientRect {} bottom: 269 height: 18 left: 797.546875 right: 1062.609375 top: 251 width: 2...
0 1789 posted 9 years ago by heathbo
Within a react component. How to gain access to the HTML that was just rendered. Any returned html element that is tagged with a ref, can easily be accessed by it's ref after it's been rendered. In the below case, use this.refs["domainModal"] to...
0 1235 posted 9 years ago by heathbo
When creating a new https://codepad.co/ snippet, the default language will be set to 'JavaScript'.
0 1194 posted 9 years ago by avansare
Regular Expression to find native Javascript console and AngularJS $log log warn or info that are NOT comments / commented out
1 1367 posted 9 years ago by brandonjp
You know that iFrames are a necessary evil for many of us. When yuo put a third party site in an iframe is always a risk because they can break out of that iframe and redirect the visitor to another location. This code acts as a defense for such case...
0 1260 posted 9 years ago by apphp-snippets
Sometimes you may want to show the visitor that you are aware of their IP address. You can do so by using few lines of code as shown here. Place the code in any place of your page, where you want the IP address to appear:
0 1264 posted 9 years ago by apphp-snippets
To do this for any object in JavaScript will not be simple or straightforward. You will run into the problem of erroneously picking up attributes from the object's prototype that should be left in the prototype and not copied to the new instance. If,...
0 1409 posted 9 years ago by BrentS
Shorthand for Ternary Operator in PHP
1 1163 posted 9 years ago by ursdeep
« Prev 1 2 3 4 5 ... 46