Plugin Author
setzer
(@setzer)
Hi wearingfilm,
Sorry for the belated response. This is a tricky problem. There’s no solution I know of that wouldn’t involve digging around in your theme or Side Matter. One rather crude approach might be to use the wp_is_mobile
conditional function in the Side Matter plugin file to tell Side Matter “if the viewer is on a mobile device, don’t load the sidenote positioning script.”
Try replacing lines 361-368 of /wp-content/plugins/side-matter/side-matter.php
with the following and see if it works:
wp_enqueue_style( 'side-matter', plugins_url( 'css/side-matter.css', __FILE__ ), null, $this->version );
if ( wp_is_mobile() ) return;
wp_enqueue_script( 'side-matter-js', plugins_url( 'js/side-matter.js', __FILE__ ), array( 'jquery' ), $this->version, true );
wp_localize_script( 'side-matter-js', 'side_matter', array(
'is_responsive' => __( $this->options['is_responsive'] ),
'use_effects' => __( $this->options['use_effects'] ),
'note_adjust' => __( $this->options['note_adjust'] ),
'html_class' => __( $this->options['html_class'] )
) );
I’d be curious to see how you’ve handled this.
Also looking for a way to keep side-matters [ref] restitution and links but stop the height adjusting in narrow browsers.
In other terms a way to switch from side-notes to end-notes.
The suggested ‘wp_is_mobile’ solution seems very blunt, and not very handy for building purposes.
Any ideas?
I would also be interested in a such a fix. On mobile, having the notes on the side isn£t practical at all. It would really be better to “transform” them into foot notes when the plugin detects that the device is a smartphone.
Thank you !
If you require assistance then, as per the Forum Welcome, please post your own topic instead of tagging onto someone else’s topic.
I am now closing this 3 month old topic as it references an older version of WordPress.