https://antibiotiqueaugmentin.com/surdosage-augmentin-bebe/

Image popups from Table JX html

  • saabeirik
  • saabeirik's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 11 months ago #2218

Hi!

This is a little "on the side" of TableJX, but I'm asking in case you've got a simple solution! :)


I'm using TableJX to display a table from a MYSQL database. One of the columns contains a html code on the form

<a href="/images/colors/92x_01G.jpg" target="_blank" onclick="window.open('/images/colors/92x_01G.jpg', 'popup', 'height=850, width=850'); return false;"> 01G</a>

It's a code to open an image in a popup window.


I'm looking for a way to get a nicer looking popup! I've looked at several solutions, but can't seem to find the right one. I've tested the extension Modalizer from Nonumber. It converts certain image links to "nice looking popups". It seems perfect, and works fine when I put the above HTML code in an article. But when I click on the link in my table, modalizer doesn't "work".

I've set up this test for demonstration.
saabarchive.net/index.php/testing

Do you have any suggestions? :)

thanks in advance for any tips!

Please Log in or Create an account to join the conversation.

More
10 years 11 months ago #2219

Hi,

what are you trying to achieve is a bit more complicated. The thing is, that most of the nice looking popups use some JavaScript code which runs trough the page and sets some properties to html links. This happens once when the page is loaded. Now if you refresh the Table JX by searching or sorting, the content of the table loads again, but the JavaScript code that makes the popup to appear does not run again.

My suggestion would be that you try to hack the Table's JavaScript code so, that it runs the popup's code again when the table is refreshed.

The place where you should put your code is in function SimpleAJAXCallback in /components/com_grid/js/grid.js

I hope you will find it heplful...

The following user(s) said Thank You: saabeirik

Please Log in or Create an account to join the conversation.

  • saabeirik
  • saabeirik's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
10 years 11 months ago #2231

Hi again!

I tried getting some help from the Modalizer developers, but I was told it probably won't work, and the extension will soon be discontinued.

Therefore I'm wondering if anyone have other tips for getting a "nicer" popup from these image links. (There will be soon be 500 of these.) Preferably something that is easy to set up! :-)

Please Log in or Create an account to join the conversation.

Moderators: tomaz
Time to create page: 0.159 seconds

Contact Us

Contact us on Discord

Contact us on Facebook