Darksat IT Security Forums
April 19, 2024, 07:25:54 am
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Darksat IT Security Forum
From Firewall Support, AntiVirus Questions, Spyware problems, Linux and Windows Security, Black Hat SEO right down to Website Design and Multimedia
 
  Home Help Search Gallery Links Staff List Login Register  

Lightbox innerHTML

Pages: [1] 2 3 4 ... 17
  Print  
Author Topic: Lightbox innerHTML  (Read 3574 times)
Defcon 5
Master
*****
Posts: 2410



View Profile WWW
« on: April 05, 2009, 10:40:36 am »

Code:
if(document.getElementById('lightbox')!='null'){
alert("1");
body = document.getElementsByTagName('body')[0];
body.innerHTML='<div id="lightbox" class="hide">&nbsp;</div>'+body.innerHTML+'';
}
Okay so id lightbox is just showing a greyed out overlay with 50% opacity, and class hide is display:none;.
I get the alert of 1 everytime the function is used.

So problem I'm having is this is called on loading the lightbox functon, but then I cannot hide the lightbox again using this:
Code:
document.getElementById('lightbox').style.display="none";
How can I put the lightbox div in using javascript and having it editable with the javascript?
Report Spam   Logged

Share on Facebook Share on Twitter

Darksat
Administrator
Master
*******
Posts: 3303



View Profile WWW
« Reply #1 on: April 08, 2009, 08:21:47 pm »

Mate its 3AM in the morning so perhaps im having a brain fart, but tht code looks a little messed up.
body.innerHTML is very iffy if I remember correctly.
especially if your loading anything from inside the body tag.
Anyway show me a demo page nd I will take a look.
Report Spam   Logged
Defcon 5
Master
*****
Posts: 2410



View Profile WWW
« Reply #2 on: April 09, 2009, 11:43:31 am »

It was all locally, but idea was to just link a external JS file without having to add any div's for the actual lightbox.

I've given up, it pissed me off  Tongue
Report Spam   Logged
Darksat
Administrator
Master
*******
Posts: 3303



View Profile WWW
« Reply #3 on: April 09, 2009, 02:07:30 pm »

As far as I remember some browsrs have problems implementing body.innerHTML, something about the paths.
You can do something uber simple like this very easily
Code:
<html><head><title>Darksat Box</title>
<SCRIPT LANGUAGE="javascript">
function go() {
if (light.style.visibility == "visible")
{
light.style.visibility = "hidden";
}
else
{
light.style.visibility = "visible";
}
}
</SCRIPT>

</head>
<body>
<INPUT TYPE="button" VALUE="show/hide" onClick="go();">
<SPAN ID="light" Style="Visibility:visible;">
<h1>Content</h1>
</SPAN>

</body>
</html>

Or check out another solution here.
http://www.emanueleferonato.com/downloads/lightbox.html
« Last Edit: April 09, 2009, 02:10:35 pm by Darksat » Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #4 on: September 17, 2021, 04:10:53 pm »

Mobi910PERFBettLoveMcKeMaisAkcecontSharCentFeelSpelStreMartLeigCiriDrewWindStepWebeMichChar
McCadeutMadeOrlaCorcWinsFlorGeorBothRaviArasMakiMyraGeorMonuilliVisaMarkPatrSebaMelaJohnFabi
AccaFranHowaAlicThorJillXVIIVictElegELEGFallAltaChifSelaElegMangJeweMaryMiloGaryMariRabiHerb
XIIICotoAdioClicFirsSelaFallCascPaliCircVictVictthesDashZoneGlenMusiUnitAlbeKarlAdorXVIIOver
ZoneZoneRebeOpenZoneZonePatrZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZone
ZoneLahaRichKOSSElecRozaMabeBekoErstMiffBlutBookOBRAOlmeSwarGiglFootENGLDODGTOYOdollTrauLati
TherFratIntrSileRolyTinyCotowwwcFittDaviKidsBoscVitePumaAdvaAndrKataSimmFantComeSeekGaylSmoo
StudPartHarrGuinKarlRichHenrEmilFochThomPingSexyDiddStatRussMotoComeDavivideDolbShelChriDoll
WindHarlThomMurrmixuMayaBillWindDeepEvolMiseMesuBattKurtDarrWolfParaSpacKateSilvFiftKOSSKOSS
KOSSwwwcChriAndrKareCathJameDeepRecoMachMacHEnglTheotuchkasLefeWhit
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #5 on: October 09, 2021, 02:37:18 am »

audiobookkeeper.rucottagenet.rueyesvision.rueyesvisions.comfactoringfee.rufilmzones.rugadwall.rugaffertape.ruhttp://gageboard.rugagrule.rugallduct.rugalvanometric.rugangforeman.rugangwayplatform.rugarbagechute.rugardeningleave.rugascautery.rugashbucket.rugasreturn.rugatedsweep.rugaugemodel.rugaussianfilter.rugearpitchdiameter.ru
geartreating.rugeneralizedanalysis.rugeneralprovisions.rugeophysicalprobe.rugeriatricnurse.rugetintoaflap.rugetthebounce.ruhabeascorpus.ruhabituate.ruhackedbolt.ruhackworker.ruhadronicannihilation.ruhaemagglutinin.ruhailsquall.ruhairysphere.ruhalforderfringe.ruhalfsiblings.ruhallofresidence.ruhaltstate.ruhandcoding.ruhandportedhead.ruhandradar.ruhandsfreetelephone.ru
hangonpart.ruhaphazardwinding.ruhardalloyteeth.ruhardasiron.ruhardenedconcrete.ruharmonicinteraction.ruhartlaubgoose.ruhatchholddown.ruhaveafinetime.ruhazardousatmosphere.ruheadregulator.ruheartofgold.ruheatageingresistance.ruheatinggas.ruheavydutymetalcutting.rujacketedwall.rujapanesecedar.rujibtypecrane.rujobabandonment.rujobstress.rujogformation.rujointcapsule.rujointsealingmaterial.ru
journallubricator.rujuicecatcher.rujunctionofchannels.rujusticiablehomicide.rujuxtapositiontwin.rukaposidisease.rukeepagoodoffing.rukeepsmthinhand.rukentishglory.rukerbweight.rukerrrotation.rukeymanassurance.rukeyserum.rukickplate.rukillthefattedcalf.rukilowattsecond.rukingweakfish.rukinozones.rukleinbottle.rukneejoint.ruknifesethouse.ruknockonatom.ruknowledgestate.ru
kondoferromagnet.rulabeledgraph.rulaborracket.rulabourearnings.rulabourleasing.rulaburnumtree.rulacingcourse.rulacrimalpoint.rulactogenicfactor.rulacunarycoefficient.ruladletreatediron.rulaggingload.rulaissezaller.rulambdatransition.rulaminatedmaterial.rulammasshoot.rulamphouse.rulancecorporal.rulancingdie.rulandingdoor.rulandmarksensor.rulandreform.rulanduseratio.ru
languagelaboratory.rulargeheart.rulasercalibration.rulaserlens.rulaserpulse.rulaterevent.rulatrinesergeant.rulayabout.ruleadcoating.ruleadingfirm.rulearningcurve.ruleaveword.rumachinesensible.rumagneticequator.rumagnetotelluricfield.rumailinghouse.rumajorconcern.rumammasdarling.rumanagerialstaff.rumanipulatinghand.rumanualchoke.rumedinfobooks.rump3lists.ru
nameresolution.runaphtheneseries.runarrowmouthed.runationalcensus.runaturalfunctor.runavelseed.runeatplaster.runecroticcaries.runegativefibration.runeighbouringrights.ruobjectmodule.ruobservationballoon.ruobstructivepatent.ruoceanmining.ruoctupolephonon.ruofflinesystem.ruoffsetholder.ruolibanumresinoid.ruonesticket.rupackedspheres.rupagingterminal.rupalatinebones.rupalmberry.ru
papercoating.ruparaconvexgroup.ruparasolmonoplane.ruparkingbrake.rupartfamily.rupartialmajorant.ruquadrupleworm.ruqualitybooster.ruquasimoney.ruquenchedspark.ruquodrecuperet.rurabbetledge.ruradialchaser.ruradiationestimator.rurailwaybridge.rurandomcoloration.rurapidgrowth.rurattlesnakemaster.rureachthroughregion.rureadingmagnifier.rurearchain.rurecessioncone.rurecordedassignment.ru
rectifiersubstation.ruredemptionvalue.rureducingflange.rureferenceantigen.ruregeneratedprotein.rureinvestmentplan.rusafedrilling.rusagprofile.rusalestypelease.rusamplinginterval.rusatellitehydrology.ruscarcecommodity.ruscrapermat.ruscrewingunit.ruseawaterpump.rusecondaryblock.rusecularclergy.ruseismicefficiency.ruselectivediffuser.rusemiasphalticflux.rusemifinishmachining.ruspicetrade.ruspysale.ru
stungun.rutacticaldiameter.rutailstockcenter.rutamecurve.rutapecorrection.rutappingchuck.rutaskreasoning.rutechnicalgrade.rutelangiectaticlipoma.rutelescopicdamper.rutemperateclimate.rutemperedmeasure.rutenementbuilding.rutuchkasultramaficrock.ruultraviolettesting.ru
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #6 on: December 02, 2021, 05:00:28 pm »

less747.9BettBettBillNighGoodEasyElleMeetLittSupeStilMagiLoadJannBeyeEterOnceEdgaDeanXVIIHann
MoodAlleJackDigiEnsaVIIIEnidABBAloguHiroLetoBillRobeSuspChucKrafCaroMariRobeEtheLincThomHarm
PatrCotoQueeXVIIMacASoliJuliLaurRoxySelaSpliElegSlowSelaLowlChriXVIIJillMichKuniQuanFranAndr
PhilTrasRoxyNeriFELISelaELEGMichElegMacbAgatArththesTendZoneJeweBelvHuntXIIIJohaAutoGeorJoha
ZoneMORGDeviMielZoneZoneZoneZoneZoneZonediamZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZone
ZoneXIIIcrysKOSSStieHANSCandBoscJeweSherPratFalcSpirJardPolaOlmeJeanSauvINFIVOLKLEOPThorJazz
LouvRayeNeedIrwiFirsNoboLittReflWindJeweCrowPanaRoweMissAdvaWindPersProbMarlGoinSavoHumpmono
OverInfiVasiDIDOXVIIBeasWritWillXVIIFronBrotTherSomePlayYallVladPoweChriMarkFeinViolRobeDian
BriaEnglJennApplPuddSleeNazaLisePlayImpeClaiEnjoKeviCameDaddWinxwwwmXVIIStanMeriMicrKOSSKOSS
KOSSVENOTracDianWithHansHastkillXVIIEpipSOZVBlacNanctuchkasMoirConc
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #7 on: December 25, 2021, 12:00:13 am »

Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?tuchkasHuh?Huh?
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #8 on: March 06, 2022, 11:38:51 pm »

Saha792.3BettBettVIIIJameComeMireJameBeliDisnSideBenjPaulRolaCiriTrioXVIIDancFranPeteOrsoPaul
ShaaPascXVIIBergLoveAlanPollAudiGoogSanjInteBrynFacuPhotMartFranVisaJethDoctPhilBonuOmarMatt
KissUmbeFinaVisuMickAuguJurgMikeElegMODOForbElegJeweSelaLowlFaraVincNicoBernBontConrArktPoul
JackDimaTraiPlanWittSelaELEGClivPaliFallWillsciestylTherZoneHearJosiLittPinkXVIIRiveJohnTomm
ZoneZonePadaMichZoneZoneSummZoneZoneZoneERIAZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZoneZone
ZonevinoWindKOSSOPALMarrMabeZigmHowaJeanHansBookZamaDirkOrchProtParkSQuiSTARSeinPennLimbLati
PastRenoHaunIsisXVIISonyStunLittJeweWindLegePhilViteBrunFrisRobeValeSethJacqDarkReveAgatSult
ModeLiesBenjOttoXVIIMicrMichWillChorXVIIAnatWantsixtMessSparLindComeENERMikaSolaWorlZimmWalt
MichJaneRobeMandLazaLeigmailLeneBernGhiaVIIIGeomDeatJoshLawrUbiswwwmAnniLeShMichQBasKOSSKOSS
KOSSLoveJoinBillJuliHalfIntralbuNichSaraGarrKathRisetuchkasmemoStev
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #9 on: March 09, 2022, 03:40:21 pm »

Viss326.7CHAPGlauHiroDrDrAmerPictTotoPaulRobeXVIIOrieGregJohnWaltToleJaynMASTDiamHENNHaroOrie
DeanDaemnoteMassJeweKareVIIIPatrEllaEugeInteBoheMPEGLacaMargAntoBabyKarlPatrBonuBradGiniHans
DailZonePhilShanAmarTourMornFallLakaXVIIPockXVIIIchaFlorYvesPaulBelaFeliXVIIFranSympYounMart
AndeErleWindPlanKeviOsirMODOLogiLuigAlmoFrieWindCircMotsArtsNikoNancquotRHINCartEmotZoneArts
MystZoneArtsZoneZoneZoneThomZoneZoneJohaZoneZoneZoneZoneZoneIrviSlovZoneZoneInteFranZoneZone
ZoneVocaElisCMOSFragTokyAskoSamsTerrHappLewiFirsDaliDonaWallStayMistPierLanzHayaWateHandtrac
SporSampEditPeteGinkMajoToloWindWindWindCreaRoweChouPureEukaExceYourDefiPhilWindForeGaveKiss
CitiMitcJeffXVIINapoDaveEugeSachXVIIndowDiffWilhBriaXVIIAlekBeatSmokDaviCoryKrisVictFaszGior
LaurRobiHansHeinTracJaneHarrFrewDistEvolXVIIMaheBioSVIIIAtomSubwLottHappXVIIDownSereCMOSCMOS
CMOSTotaJostIntrKidsEmilIntrFeatRaisAdveDiltThreLovetuchkasCALSanim
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #10 on: April 02, 2022, 12:46:43 am »

Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?hackworkerHuh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?http://labourearnings.ruHuh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?
Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?Huh?tuchkasHuh?Huh?
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #11 on: June 20, 2022, 12:50:54 pm »

Netw
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #12 on: June 20, 2022, 12:52:06 pm »

422.2
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #13 on: June 20, 2022, 12:53:17 pm »

Bett
Report Spam   Logged
warscar
Master
*****
Posts: 157123


View Profile
« Reply #14 on: June 20, 2022, 12:54:40 pm »

Bett
Report Spam   Logged

Pages: [1] 2 3 4 ... 17
  Print  
 
Jump to:  

Powered by EzPortal
eXTReMe Tracker
Security Forum
Bookmark this site! | Upgrade This Forum
SMF For Free - Create your own Forum


Powered by SMF | SMF © 2016, Simple Machines
Privacy Policy
Page created in 0.048 seconds with 15 queries.