Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Aug 17 09:32
    User @bjorno43 unbanned @linkin-park
  • Jun 20 21:19
    @bjorno43 banned @shenerd140
  • Apr 25 17:13
    @mstellaluna banned @cmal
  • Jan 08 22:05
    @mstellaluna banned @dertiuss323
  • Nov 07 2018 04:42
    User @texas2010 unbanned @ows-ali
  • Nov 02 2018 16:25
    @texas2010 banned @ows-ali
  • Oct 12 2018 05:50
    @bjorno43 banned @NACH74
  • Oct 05 2018 23:02
    @mstellaluna banned @JomoPipi
  • Sep 16 2018 12:21
    @bjorno43 banned @yash-kedia
  • Sep 16 2018 12:16
    @bjorno43 banned @vnikifirov
  • Sep 05 2018 08:12
    User @bjorno43 unbanned @androuino
  • Sep 05 2018 07:38
    @bjorno43 banned @androuino
  • Aug 23 2018 16:57
    User @bjorno43 unbanned @rahuldkjain
  • Aug 23 2018 16:23
    @bjorno43 banned @rahuldkjain
  • Jul 29 2018 14:13
    User @bjorno43 unbanned @jkyereh
  • Jul 29 2018 01:00
    @bjorno43 banned @jkyereh
  • Jul 10 2018 22:09
    @bjorno43 banned @manafn
  • Jul 06 2018 15:20
    @texas2010 banned @imlegend19
  • Jul 03 2018 12:28
    @bjorno43 banned @vbvmatta
  • Jun 29 2018 13:54
    @bjorno43 banned @OGTechnoBoy
AbrisM
@AbrisM
?
Programming/Software Developer
I also do Web Design
AbrisM
@AbrisM
Next I will be doing Networking :)
Muna Mohamed
@mooneyd12
Hi everyone! Is there anyone that can help me with a Javascript problem?
I'm trying to decrease the scale of an element using a Javascript for loop when an a tag is clicked but just can't seem to figure out
Sorin Ruse
@sorinr
@mooneyd12 can u post your code on codepen and share the link?
Muna Mohamed
@mooneyd12
hi! sorry I just say your post
Chris Tram
@ctram
One thing is, 'main-content' is an id, but you're are using the method to find by class, no?
Muna Mohamed
@mooneyd12
oh yes, my mistake. I corrected it
I think without some sort of timing function added it won't work but I'm not sure how to add one
Sorin Ruse
@sorinr
@mooneyd12 why do you make the page responsive by using js and not css?
Muna Mohamed
@mooneyd12
I haven't added responsiveness to the page yet @sorinr
I wanted to get the animation and transitions out the way first @sorinr
ohh you mean making the page interactive....it's because I'm trying to get out of my comfort zone of css and venture into more javascript
@sorinr
Sorin Ruse
@sorinr
@mooneyd12 no. i meant why would you scale an element by js and not css?
Muna Mohamed
@mooneyd12
Ahh I see, the reason is because I can't apply the css transition to the parent (#main-content) using the child element (the a tag), @sorinr
so I thought using js might be easier to do this with @sorinr
Chris Tram
@ctram
@mooneyd12 Not sure why you cannot directly set the transform attribute; also, the method is getElementById, singular.
Can you have the function use the loop, but change the classes?
Chris Cullen
@123xylem

Hi - I have this image gallery that I want to show the title of when hovered over. Any idea how to select the title attribute on hover?

#envira_shortcode_id_444 > a:hover {
transform:scaleX(2.3);
    transition:all 0.3s ease-in;
}

#envira_shortcode_id_444 > a:hover a[title]{
    color:white;
    position:absolute;
    top: 50%;
left: 50%;

}

Thats how im trying to select it which seems to work for most of it but not for the title attribute

The developer tools shows this for the title attribute::

<img id="envira-gallery-image-445" class="envira-gallery-image envira-gallery-image-1" data-envira-index="1" src="https://www.webdevchris.ga/wp-content/uploads/2017/12/pexels-photo-160107-1024x682-410x273_c.jpeg" data-envira-src="https://www.webdevchris.ga/wp-content/uploads/2017/12/pexels-photo-160107-1024x682-410x273_c.jpeg" data-envira-gallery-id="444" data-envira-item-id="445" data-envira-caption="Web Development" alt="HTML5, CSS3,  JavaScript,  WordPress,  NodeJS, Express  MongoDB,  Site Authentication,  Git GitHub" title="Web Development" itemprop="thumbnailUrl" data-envira-srcset="https://www.webdevchris.ga/wp-content/uploads/2017/12/pexels-photo-160107-1024x682-410x273_c.jpeg 400w,https://www.webdevchris.ga/wp-content/uploads/2017/12/pexels-photo-160107-1024x682-410x273_c.jpeg 2x" srcset="https://www.webdevchris.ga/wp-content/uploads/2017/12/pexels-photo-160107-1024x682-410x273_c.jpeg" style="opacity: 1;">

the site is www.webdevchris.ga
Thanks Guys!

its the envira gallery with 3 images at the top
Chris Tram
@ctram
@123xylem You want to change the styling of the tooltip that appears based on the title attribute? https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/title
e.g. <a title="i pop up for the link">I am a link</a>
?
Muna Mohamed
@mooneyd12
I have tried doing that but still no luck @ctram
someone suggested using css instead so I'm playing around with css animations atm @ctram
Chris Cullen
@123xylem
@ctram hi
when i hover on the image i want the title to appear
@ctram so im trying to target the images title attribute
and show it on hover
Adel
@AdelMahjoub
@123xylem easiest using javascript I guess, but maybe because I'm not really good with css
@123xylem but if all those data attributes are rendered with a templating engine, put the title in the center of the image with display: none, and on hover set it to display block
@123xylem kinda of a barbaian css but it should work
Chris Cullen
@123xylem
@AdelMahjoub its wordpress so its not so customisable
Adel
@AdelMahjoub
@123xylem not even an inline script ?
Chris Cullen
@123xylem
well i have a additional css area to add css
can i add a script to that?
Adel
@AdelMahjoub
@123xylem if you can read the php file, you could easily add a script under the images section
Chris Cullen
@123xylem
Im customising a plugin
Adel
@AdelMahjoub
@123xylem open the php file and add a script tag and the logic inside a function like this, so nothing unexpected should happen
(function(){
/* script */
})()
Chris Cullen
@123xylem
@AdelMahjoub its a bit above me
its a plugin so I dont have access to the php files
Adel
@AdelMahjoub
@123xylem simple, all inline javascript is parsed while the browser is building the dom, you edit that php page and add <script></script> just under the images section
@123xylem and wrap the javascript that you'll write inside a function like above
Chris Cullen
@123xylem
@AdelMahjoub I could add custom html
and add the images in it maybe
instead of the envira plugin