Questions tagged [javascript]

JavaScript is a dynamically-typed language commonly used for client-side scripting. Unless a tag for a framework/library is also included, a pure JavaScript answer is expected.

Filter by
Sorted by
Tagged with
2
votes
4answers
2k views

How can I insert js scripts before </body>

I know this question is been asked again, but i tried their solution and it doesn't work so please don't rate it down. I have an authentication script (auth.js) that needs to be placed before the tag,...
3
votes
1answer
723 views

Placing inline javascript into the head tags of one page only

I'm using the Sourcerer extension to send script to my header tags on specific pages to comply with the new gtag requirements of placing conversion tags in the head tags of pages that you want to ...
2
votes
1answer
417 views

How do I add “id” to script declaration

In the example below, the loaded script will appear in the 'head' with a plain 'script' tag but how do I add an id into the declaration so the result is something like 'script id="my-script"' $...
-2
votes
1answer
33 views

FutureProspect Theme How to deactivate the top toggling effect?

I am using the FutureProspect template on my Joomla website. The only issue what I am facing is the availability of the following effect, which is irritating on the mobile effect: Kindly let me ...
0
votes
1answer
92 views

How to insert tracking JS code (snippet) into Piwigo gallery?

Javascript code for tracking which was incorporated into Joomla installation through a Custom HTML module has no effect on Piwigo gallery. How visits to the gallery could be tracked, i.e. where the ...
1
vote
2answers
47 views

Test site not rendering template list php error

Okay, so we have a section of our server portioned off to be a nested test site. However for whatever reason the below template causes an error in Joomla's php handler that it does not on the active ...
0
votes
1answer
259 views

Parsing Error Javascript in php include page on the test server

We're getting this error in our test environment: Parse error: syntax error, unexpected 'var' (T_VAR) in /home/usaspo5/public_html/dev/usgnew/components/com_usg_programs/tmpls/default.php We have ...
2
votes
1answer
878 views

custom table display - help turning static html to dynamic php

I am trying to modify the list view of my Joomla component to display my table's data in a more user-friendly fashion. It currently simply displays all data in a regular table with columns and rows, ...
3
votes
1answer
736 views

Send array from javascript to php by POST in Joomla 3.x

im trying to send an array from javascript to Joomla 3.x php file. var options = ['foo', 'bar']; $.post('index.php?option=component&view=componentview&Itemid=123&tmpl=component&...
1
vote
1answer
164 views

render/execute jasvscript code (which is in a php string) inside virtuemart JDispatcher eg: plgVmConfirmedOrder

I want to render/execute some javascript code written inside virtuemart JDispatcher eg: plgVmConfirmedOrder eg: $script='console.log("this is dummy script");jQuery.ajax({url:'',type:'post',success:...
4
votes
2answers
1k views

how to display message in joomla using javascript

I want to display a message after clicking a button in Joomla using: Joomla.renderMessages({"success":"this is test message"}); but it displays the characters vertically and in descending order, ...
1
vote
2answers
368 views

How do I implement Google Analytics userID feature in Joomla 2.5 for logged in users with PHP?

My Joomla template includes the analyticstracking.php file with the tracking script, which has worked great, however I'd like to implement Google Analytic's userID feature (for cross-device tracking) ...
1
vote
1answer
167 views

RSform- scroll screen up when posting from one form to another

I have a form built with RSForm pro on my website home page and when user submit that, it redirects them to a second form (booking form) and auto populate the fields selected on first form. Im ...
1
vote
0answers
336 views

RSForms - Change the items of a radio group based on a selection of a drop down

I need to change the items of a radio group based on a drop-down selection in RSForm pro. Right now I'm using the Conditional Fields feature to show different radio group field and that caused too ...
1
vote
2answers
231 views

best way to add third party js and css

I need to add a third party js and CSS to my template head. I'm getting Leverage browser caching and someone advised me to load the files locally. created a directory in root: assets/third-party/ ...
1
vote
1answer
2k views

Run External PHP File From Joomla Article

I have a php file that will echo results in the end of the file. I want to from an onclick event fire some Javascript that will call this php file and print the results on screen. My javascript ...
1
vote
1answer
50 views

Run Code From Joomla Article

Is it possible to run JQuery or JavaScript in a Joomla Article? I ask because I have tried just about every possible option I see on forums/interwebs and the data does not display as I desire.
2
votes
1answer
527 views

Template Modal Conflict

Joomla 3.6.5 Joomshaper Helix 3 Template link FavimageHover Module link I have the FavimageHover module installed on my site, it works great until I try and add images via the front-end. There seems ...
1
vote
1answer
4k views

How to get the active language variable in javascript on a multilingual site?

So, I'm trying to modify the Facebook Devkit script that is in my index.php to change depending the on the website's active language, but I'm not sure how to access the active language variable. I ...
2
votes
6answers
893 views

What's the correct way of adding code after the start of the body tag?

So, I've just recently added the Facebook Javascript SDK to my site to be able to enable a "like" button to my pages. Facebook recommends adding this right after the opening <body> tag. The ...
0
votes
1answer
411 views

Using a JQuery function in a module?

I have customised a small text rotator using Jquery which I wish to use to rotate phones numbers in a module.It can be found here: http://jsfiddle.net/tovic/xaqgn/ I have tried embedding the function ...
3
votes
1answer
290 views

Where to call for CSS/JS in custom component for frontend views

I've created a custom component with a dashboard that needs styling with CSS. I've created the CSS file and I'm looking at calling for it in the frontend view. Working with J! 3.6.5 and a MVC ...
2
votes
1answer
1k views

Add script just after <head>

I'm registering to Google AdSense. In order to check the site they want that I put a piece of code inside (<script>something</script>) just after <head> tag. How can I do it?
1
vote
0answers
42 views

stop reloading the page when choosing a payment method in virtuemart checkout

on virtuemart checkout process, on choosing the payment method, when click on the radio button, page reloads. i have wrote a function that does something when page reloads or refreshes. but the ...
4
votes
2answers
320 views

How to use joomla language in a script?

I'm developing a module, in my template (MyModule/tmpl/default.php) I'm able to bring my language string to my script by doing this : <script type="text/javascript"> Mymodule.options.mydz = {...
0
votes
1answer
412 views

page reloads when using document.getElementById

Im using the js function shown below to make a part of page disappear when user clicks on the button. but when i click on the button, the part disappears, but page reloads. why is it like this? <...
1
vote
2answers
129 views

Easiest way to make a dynamic 'assessor' or 'quiz'

I was working on a Joomla website with mainly HTML + CSS. I'm learning Java, but have barely any experience in JavaScript, though when reading the code I can eventually understand it. All I wanted ...
0
votes
1answer
67 views

ReferenceError: openMyModalNew is not defined error in Ijoomla Guru 5 [closed]

Little time ago I install Ijoomla Guru 5 and only now I realize that tutorials not opening in modal window. I get error ReferenceError: openMyModalNew is not defined. As right now I haven't access to ...
1
vote
2answers
496 views

Add <script> tag before </body> on only certain pages?

I am fairly new to Joomla (using for less than a year) and I need to find a way to place a script tag before the tag in joomla. This is for marketing (call tracking) purposes. I have seen some ...
3
votes
1answer
750 views

how to Validate captcha before submit a form in joomla

I have installed 5 captcha plugins in my joomla site and i set any one captcha out of 5 in com_users configuration in backend of joomla. So how can I want to validate that captcha from client browser ...
0
votes
2answers
125 views

Extreme Joomla Optimization

Hello all Joomla StackExchange users, I am developing I site which is particularly complex and uses a lot of CSS and JS assets to work properly. Usually, I would fine tune JCH Optimize to get the work ...
0
votes
1answer
398 views

Virtuemart conflicts in dropdown only sometimes

I am using Virtuemart and enalbled a "Multi-Variant" options. It nearly works, in the sense that only sometimes the product page (which has the custom options dropdowns) gives a JavaScript error. Some ...
0
votes
2answers
74 views

Accessing Jdatabase via JavaScript Or Passing PHP varibles to JavaScript

I want to use this SVG Pie Chart on my Joomla site but the problem is I need to access data from Jdatabase and feed it to its index.js $(function(){ $("#pieChart").drawPieChart([ { title: "Cash"...
0
votes
1answer
353 views

Please correct the path for Joomla Javascript Async and Defer plugin

Hello i want to Defer parsing of JavaScript of the following link in joomla by using Javascript Async and Defer plugin. http://www.domain.com/media/plg_jchoptimize/assets/gz/1/0/...
1
vote
1answer
65 views

jQuery UI issue with jQueryEasy plugin

Hello I have an old Joomla 2.5 site. I use the jQueryEasy for optimization and if I dont I get some random mootools error. My issue is : I want to use the draggable() method of jQuery UI. It seems ...
1
vote
1answer
911 views

Can't insert intro/full article image

For some strange reason I cannot insert intro/full article image in articles anymore. On "Images and Links" tab, I click on button to add images. Popup screen appears and then I paste image url in "...
0
votes
1answer
39 views

Javascript errors showing on site, assets folder not found

This page: http://www.smithsdetection.com/index.php?option=com_k2&view=item&id=19:prime-alert&Itemid=1417&lang=en#.V4YfGzVctmM is showing the various javascript errors: When you ...
0
votes
1answer
122 views

remove Js alert in home page

I dont know whats the probleme , to be honest i have no idea how joomla works i have a joomla website and every time i visit the homepage a JS alert shows up i really could not find the solution , ...
0
votes
1answer
87 views

Event Booking - Javascript error on function

I started having a strange error on some pages. The website has been working fo the last 3 years with no problem. We sell IT courses and have pages for both individual and group registration. Group ...
1
vote
1answer
333 views

Bootstrap 3 Carousel not starting automatically

I am having trouble getting my bootstrap 3 carousel to work. On the site it will automatically advance if you first click to advance a slide. I have disabled the pause on hover. I tested it on Code ...
0
votes
2answers
670 views

Upgraded from 2.5 to 3.5 : Joomla.JMultiSelect, Class is not defined

I've upgraded an old site from 2.5 to 3.5 and have managed to fix everything except this error : Uncaught ReferenceError: Class is not defined @ multiselect.js:12 Uncaught TypeError: Joomla....
1
vote
1answer
160 views

How do I resolve the conflict between MB2 Portfolio component slider and /media/system/js/mootools-core.js?

I am using MB2 Portfolio with the built in slider to display some projects. The problem is that every other image in the sliders collapse. Inspecting them with FireBug shows that every other div is ...
1
vote
0answers
14 views

Need some suggestion regarding strategy of scraping article view times from another webpage to use in K2 item

I am building a video blog page using Joomla 3.0 + k2 hosted on my own Ubuntu 14.04 server, the videos will be uploaded to sites like youtube or vimeo too. I want to show the viewed times of the ...
2
votes
1answer
2k views

Run MySQL Query From Button Click

How can I run a MySQL query from the onclick event of an HTML button on my site? For example if my button is created like so, how could I use this to run a MySQL query titled AddInfo <p><...
1
vote
1answer
935 views

Is it possible to override js scripts?

I'm using a layout override to modify the cart module for Virtuemart, but the ajax request deletes part of my code when it updates. Because of this, I would like to change not only the template, but ...
1
vote
1answer
64 views

Assigning ID to javascript function

I am developing a module (see here for details Mixing PHP variables and JS variables in output) this shows multiple uses of the same javascript function, as follows: $key = $params->get('key');...
2
votes
1answer
141 views

Mixing PHP variables and JS variables in output

I am trying to develop a module to use JWPlayer's URL Toekn Signing (docs can be found here http://developer.jwplayer.com/jw-platform/reference/v1/content_signing.html) but I'm having an issue with ...
1
vote
0answers
117 views

Plugin conflict troubleshooting

Joomla 3.4.8. T3 Joomlart JA University Template I have been experiencing some conflicts certain plugins I have installed on my site, two in particular - only one of them seems to work at a time. ...
2
votes
1answer
102 views

mb2portfolio increase skills limit

I am using a component called mb2portfolio with Joomla 3.4.8 and I'm having difficulties with the skills limit. It seems that the skills limit is set at 12, but I need 25 as the limit. Please could ...
1
vote
1answer
719 views

Passing form value using Ajax

Referring to my previous Question jQuery Ajax for three drop down On page1) I will select dropdown Building (populating from db) and dropdown Floor (by Ajax call) then url will pass like: index....