Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

MooTools Help

Featured Replies

Heya,

 

Before anyone says anything: I have to use MooTools.

 

So basically I have a few rows in a table that have been outputted from a database. In each of these rows there is an link, which should make a div/row appear below the row link that they clicked on.

 

I have this working for the very first row, however I need it to be working so each row has a seperate slide down part to it.

 

Simplified code:

 

<tr>
<td><a id='v_toggle' href='#'>Toggle</a></td>
</tr>


<tr id='vertical_slide'>
<td>Toggled content</td>
</tr>

 

The MooTools/JS:

 

<script language="Javascript" type="text/javascript">
window.addEvent('domready', function() {

   // -- horizontal
  var myVerticalSlide = new Fx.Slide('vertical_slide', {mode: 'vertical'});
 myVerticalSlide.hide();

  $('v_toggle').addEvent('click', function(event){
 event.stop();
 myVerticalSlide.toggle();
  });
});
</script>

 

That works for the very first row, but as said, I would like it to work for each :)

 

I assume there needs to be some kind of "this" word put in somewhere (like jQuery).

  • Author

Anyone?

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.