Want to add a slide gallery into a page in html- currently using i-frame because of standard img size in added slide gallery
Code Forum
by Edrol97
1d ago
https://codepen.io/Eliot-Lord/live/jEONLYG Hi all, Wondering how to make a slide gallery in html on an existing page. I have multiple existing imgs in my code already and I want to assign a style to all of the slide gallery imgs without assigning it to other imgs. I also want the gallery to appear max-height and max-width as currently am displaying it in an iframe which is tricky. Full code for additional gallery below HTML: <h2 >Headline... Read more ..read more
Visit website
Update! Weekend Challenge: Still no idea what to do on the weekend?
Code Forum
by ratwolf
2d ago
Below a fixed example for a 3D sphere Challenge: Design and implement an algorithm that takes as input a smooth, parametrically defined 3D surface described by analytic formulas. This algorithm should automatically determine a suitable projection center for stereographic projection and compute the corresponding 2D projection. The algorithm should then reconstruct the original 3D surface from this 2D projection. The quality of the projection (projection center selection) and the... Read more ..read more
Visit website
How to add Shrove Tuesday and lent to this script
Code Forum
by john wytonsite
2d ago
(function(){ var linebreak = true, // should line break be added after date and holidays (if any) (true/false) calendar = new Date(), day = calendar.getDay(), month = calendar.getMonth(), date = calendar.getDate(), year = calendar.getFullYear(), f = Math.floor, cent = f(year / 100), g = year % 19, k = f((cent - 17) / 25), i = (cent - f(cent / 4) - f((cent - k) / 3) + 19 * g + 15) % 30, i = i - f(i / 28) * (1 - f(i / 28) * f(29 / (i+1)) * f((21-g) / 11)), j = (year + f(year /... Read more ..read more
Visit website
Weekend Challenge: Still no idea what to do on the weekend?
Code Forum
by ratwolf
2d ago
Below a fixed example for a 3D sphere Challenge: Design and implement an algorithm that takes as input a smooth, parametrically defined 3D surface described by analytic formulas. This algorithm should automatically determine a suitable projection center for stereographic projection and compute the corresponding 2D projection. The algorithm should then reconstruct the original 3D surface from this 2D projection. The quality of the projection (projection center selection) and the... Read more ..read more
Visit website
Still no idea what to do on the weekend?
Code Forum
by ratwolf
3d ago
Python: import numpy as np import matplotlib.pyplot as plt from mpl_toolkits.mplot3d import Axes3D # Generate a 3D sphere theta = np.linspace(0, np.pi, 30) phi = np.linspace(0, 2 * np.pi, 60) theta, phi = np.meshgrid(theta, phi) # Convert spherical coordinates to Cartesian (3D) x = np.sin(theta) * np.cos(phi) y = np.sin(theta) * np.sin(phi) z = np.cos(theta) # Stereographic Projection (3D -> 2D) x_proj = x / (1 - z) y_proj = y / (1 - z) # Inverse Projection (2D -> 3D) x_recon = (2 * x_proj) /... Read more ..read more
Visit website
How to send a div to the Windows Print Dialog at the correct scale for A1/A4 etc.
Code Forum
by Messy
3d ago
I have a div that displays user-edited content ready to be sent to the Windows Print Dialog for printing. The content contains images and text at a width of 7016px, which is the width of A1 at 300dpi. I have a button to print at A1 and a button to print at A4. The A4 button changes the width to 2480px to fit onto A4 paper. But when the dialog opens, the image is huge and takes up about 7 pages of A4 paper. In order for the image to fit I need to manually change the scale to 10. How can I... Read more ..read more
Visit website
SetTimeout() not working
Code Forum
by JLeger91
5d ago
The screen looks like the above and the background bogs up and down. A lightning flash can happen and tests successfully. However, the SetTimeout() timer that has lightning flash every now and then is not working. Here is where the animate() function happens and where the timeout is called and it doesn't work. Here is where the lightning effect is coded and it works successfully if there is no timeout ..read more
Visit website
Lets talk about Deepseek
Code Forum
by simong1993
1w ago
Hey All, so i want to talk about my favourite topic and i one i know @Antero360 loves alot ? Deepseek, so as a AI nut trying everything you can think off Deepseek seems to good to be true, i tried it and it seems to be better then GPT but better then Claude now i dont know and with its API being free i mean it could be a game changer, Anyone else tried it before ..read more
Visit website
Absolutely positioned div with 2 child divs collapses in Safari only
Code Forum
by svoltmer
1w ago
I have a CSS animation with an absolutely positioned wrapper div and 2 sibling child divs with text, but the wrapper collapses in Safari and doesn’t honor the child elements inside of it. Is there a workaround? Here is the page with the issue in the header image. Innovation Grove | Rose-Hulman ..read more
Visit website
Background bogging up and down
Code Forum
by JLeger91
1w ago
When I delete hit_top variable in script.js and roomEffects.js that is sent into the function, then the background scrolls upwards as it should. But without the hit_top variable, how can I tell the program that the background has already been to the top of the screen? It should look like a bogging ship. In script.js Code: import { bog_ship } from './roomEffects.js'; const canvas = document.getElementById('canvas1'); const ctx = canvas.getContext('2d'); const CANVAS_WIDTH = canvas.width = 640... Read more ..read more
Visit website

Follow Code Forum on FeedSpot

Continue with Google
Continue with Apple
OR