473,804 Members | 3,697 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Rotating content for table cells

I am designing a table with 2 columns and 20 rows. I want to insert
small images (each with a link) and a text title in each cell of the
table.

On refresh of the page, I would like to have the contents of each cell
(picture/link and associated text) rotate randomly.

Note that the text titles must remain with their associated picture
and link (I don't want to scramble all the elements--just rotate the
entire contents of the table cell).

Is there a script that will accomplish this? Thanks.
Jul 23 '05
31 7050
"Dr John Stockton" <sp**@merlyn.de mon.co.uk> wrote in message
news:GL******** ******@merlyn.d emon.co.uk...
JRS: In article <Nzwqd.160663$H A.32847@attbi_s 01>, dated Mon, 29 Nov
2004 03:20:18, seen in news:comp.lang. javascript, McKirahan
<Ne**@McKirahan .com> posted :
function numbers() {
var url = "http://www.topsearchsp ot.com/";
var gif = new Array(10);
gif[0] = "0.gif|Zero ";
gif[1] = "1.gif|One" ;
gif[2] = "2.gif|Two" ;
gif[3] = "3.gif|Thre e";
gif[4] = "4.gif|Four ";
gif[5] = "5.gif|Five ";
gif[6] = "6.gif|Six" ;
gif[7] = "7.gif|Seve n";
gif[8] = "8.gif|Eigh t";
gif[9] = "9.gif|Nine ";
for (var i=0; i<gif.length; i++) {
gif[i] = url + gif[i];
}


Only a list of the names of the digits is needed; javascript can
assemble the rest when needed.

var Digits = ["Zero", ..., "Nine"] // is simpler.


Simpler, yes -- but not applicable. If you had read the complete thread you
would see that my post was just an example of how to handle multiple images
and their corresponding text.
Jul 23 '05 #11
I wasn't looking for terribly elegant code, as long as it works.

Many thanks!

"McKirahan" <Ne**@McKirahan .com> wrote in message news:<bzHqd.117 307$5K2.72093@a ttbi_s03>...
"Royal Denning" <ro***********@ hotmail.com> wrote in message
news:4e******** *************** ***@posting.goo gle.com...
McK: It worked! Thanks so much.

My only remaining questions:

How do I plug in the separate URLS (relative links, such at one.htm,
two.htm, etc.) to each image,

and can I use the same script twice on a page (using different array
values, such at 11-20?

I really appreciate your patience and guidance on this.


Not the most elegant code ....

Jul 23 '05 #12
"McKirahan" <Ne**@McKirahan .com> wrote in message news:<l7Kqd.118 122$5K2.23354@a ttbi_s03>...
"Dr John Stockton" <sp**@merlyn.de mon.co.uk> wrote in message
news:GL******** ******@merlyn.d emon.co.uk...
JRS: In article <Nzwqd.160663$H A.32847@attbi_s 01>, dated Mon, 29 Nov
2004 03:20:18, seen in news:comp.lang. javascript, McKirahan
<Ne**@McKirahan .com> posted :
function numbers() {
var url = "http://www.topsearchsp ot.com/";
var gif = new Array(10);
gif[0] = "0.gif|Zero ";
gif[1] = "1.gif|One" ;
gif[2] = "2.gif|Two" ;
gif[3] = "3.gif|Thre e";
gif[4] = "4.gif|Four ";
gif[5] = "5.gif|Five ";
gif[6] = "6.gif|Six" ;
gif[7] = "7.gif|Seve n";
gif[8] = "8.gif|Eigh t";
gif[9] = "9.gif|Nine ";
for (var i=0; i<gif.length; i++) {
gif[i] = url + gif[i];
}


Only a list of the names of the digits is needed; javascript can
assemble the rest when needed.

var Digits = ["Zero", ..., "Nine"] // is simpler.


Simpler, yes -- but not applicable. If you had read the complete thread you
would see that my post was just an example of how to handle multiple images
and their corresponding text.


Hmm...what about those with JS disabled? Not much help...

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt d">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>untitled </title>
<!-- DEMO ONLY -->
<base href="http://i.office.micros oft.com/i/0000/MR/" />
<!-- DEMO ONLY -->
<style type="text/css">

body {
font-size: 100%;
margin: 12px;
background: #000;
}
#container {
width: 458px;
margin: 10px auto;
}
#rotator1, #rotator2 {
float: left;
margin: 10px;
border-collapse: collapse;
border: 4px #fff;
border-style: groove ridge groove groove;
background: #000;
}
#rotator1 td, #rotator2 td {
text-align: center;
padding: 1px;
margin: 0;
}
td a:link, td a:visited {
font: normal 60% verdana, sans-serif;
color: #fff;
text-decoration: none;
}
td a:hover {
text-transform: uppercase;
}
td a img {
display: block;
border-width: 0;
}

</style>
<script type="text/javascript">
//<![CDATA[

var table_ids = [ 'rotator1' , 'rotator2' ];

function Rotator(table_i d)
{
this.table = document.getEle mentById(table_ id);
this.cells = this.table.getE lementsByTagNam e('TD');
this.ncells = this.cells.leng th;
this.pix = [];
this.txt = [];
this.hrefs = [];
this.idx_array = new Array(this.ncel ls);

function read()
{
var cell, n = 0;
while (cell = this.cells.item (n++))
{
this.pix.push(c ell.getElements ByTagName('IMG' )[0].src);
this.txt.push(c ell.getElements ByTagName('A')[0].lastChild.node Value);
this.hrefs.push (cell.getElemen tsByTagName('A' )[0].href);
}
this.shuffle();
}
this.read = read;

function shuffle()
{
var idx, i, ind1, ind2, temp;
for (i = 0; i < this.ncells; ++i)
this.idx_array[i] = i;
for (i = 0; i < this.ncells; ++i)
{
ind1 = Math.floor(Math .random() * this.ncells);
ind2 = Math.floor(Math .random() * this.ncells);
temp = this.idx_array[ind1];
this.idx_array[ind1] = this.idx_array[ind2];
this.idx_array[ind2] = temp;
}
this.write();
}
this.shuffle = shuffle;

function write()
{
var cell, el, idx, n = 0;
while (cell = this.cells.item (n))
{
idx = this.idx_array[n++];
cell.getElement sByTagName('IMG ')[0].src = this.pix[idx];
(el = cell.getElement sByTagName('A')[0]).lastChild.nod eValue =
this.txt[idx];
el.href = this.hrefs[idx];
}
this.table.styl e.visibility = 'visible';
}
this.write = write;

this.read();
}

onload = function()
{
if (document.getEl ementById && document.create Element)
for (var i = 0; i < table_ids.lengt h; ++i)
new Rotator(table_i ds[i]);
}

/* set initial visibility to hidden */
if (document.getEl ementById && document.create Element)
{
for (var s = '', i = 0; i < table_ids.lengt h; ++i)
s += '#' + table_ids[i] + ',';

document.write(

'<style type="text/css">' ,
s.replace(/,$/, '') ,
'{visibility:hi dden;}' ,
'</style>'

);
}

/* demo only */
function dummy(link)
{
alert(link.href );
return false;
}

//]]>
</script>
</head>
<body>
<div id="container" >
<table id="rotator1">
<tbody>
<tr>
<td><a href="#displays " onclick="return dummy(this)"><i mg
src="j0399/j0399836.gif" />displays</a></td>
<td><a href="#diskette " onclick="return dummy(this)"><i mg
src="j0323/j0323552.gif" />diskette</a></td>
</tr>
<tr>
<td><a href="#floppies " onclick="return dummy(this)"><i mg
src="j0233/j0233109.gif" />floppies</a></td>
<td><a href="#monitor" onclick="return dummy(this)"><i mg
src="j0316/j0316344.gif" />monitor</a></td>
</tr>
<tr>
<td><a href="#mouse" onclick="return dummy(this)"><i mg
src="j0382/j0382582.gif" />mouse</a></td>
<td><a href="#dishes" onclick="return dummy(this)"><i mg
src="j0237/j0237779.gif" />dishes</a></td>
</tr>
<tr>
<td><a href="#cams" onclick="return dummy(this)"><i mg
src="j0396/j0396846.gif" />cams</a></td>
<td><a href="#pcs" onclick="return dummy(this)"><i mg
src="j0399/j0399981.gif" />pcs</a></td>
</tr>
<tr>
<td><a href="#birds" onclick="return dummy(this)"><i mg
src="j0198/j0198718.gif" />birds</a></td>
<td><a href="#recycle" onclick="return dummy(this)"><i mg
src="j0323/j0323582.gif" />recycle</a></td>
</tr>
</tbody>
</table>
<table id="rotator2">
<tbody>
<tr>
<td><a href="#kitty" onclick="return dummy(this)"><i mg
src="j0326/j0326434.gif" />kitty</a></td>
<td><a href="#kite" onclick="return dummy(this)"><i mg
src="j0231/j0231947.gif" />kite</a></td>
</tr>
<tr>
<td><a href="#telescop e" onclick="return dummy(this)"><i mg
src="j0287/j0287221.gif" />telescope</a></td>
<td><a href="#keys" onclick="return dummy(this)"><i mg
src="j0287/j0287325.gif" />keys</a></td>
</tr>
<tr>
<td><a href="#earth" onclick="return dummy(this)"><i mg
src="j0400/j0400664.gif" />earth</a></td>
<td><a href="#choo-choo" onclick="return dummy(this)"><i mg
src="j0234/j0234231.gif" />choo-choo</a></td>
</tr>
<tr>
<td><a href="#bus" onclick="return dummy(this)"><i mg
src="j0395/j0395931.gif" />bus</a></td>
<td><a href="#chips" onclick="return dummy(this)"><i mg
src="j0318/j0318944.gif" />bull !</a></td>
</tr>
<tr>
<td><a href="#shot-put" onclick="return dummy(this)"><i mg
src="j0303/j0303464.gif" />shot-put</a></td>
<td><a href="#pointer" onclick="return dummy(this)"><i mg
src="j0281/j0281730.gif" />pointer</a></td>
</tr>
</tbody>
</table>
</div>
</body>
</html>
Jul 23 '05 #13
RobB wrote:
<snip>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt d">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
lang="en"> <snip> document.write(

'<style type="text/css">' ,
s.replace(/,$/, '') ,
'{visibility:hi dden;}' ,
'</style>'

);

<snip>

Currently there are no XHTML DOM implementations that support
document.write.

Richard.
Jul 23 '05 #14
"RobB" <fe******@hotma il.com> wrote in message
news:ab******** *************** ***@posting.goo gle.com...

[snip]
Hmm...what about those with JS disabled? Not much help...


[snip]

Well, it was asked in a JS group which begs for a JS solution.
Jul 23 '05 #15
On Tue, 30 Nov 2004 10:19:39 GMT, McKirahan <Ne**@McKirahan .com> wrote:
"RobB" <fe******@hotma il.com> wrote in message
news:ab******** *************** ***@posting.goo gle.com...

[snip]
Hmm...what about those with JS disabled? Not much help...


[snip]

Well, it was asked in a JS group which begs for a JS solution.


So? A document that uses Javascript should never fail just because that
*optional* technology is disabled. A controlled environment might give you
more freedom, but as far as the Web is concerned, client-side scripting
should be an enhancement only.

Mike

--
Michael Winter
Replace ".invalid" with ".uk" to reply by e-mail.
Jul 23 '05 #16
"Michael Winter" <M.******@bluey onder.co.invali d> wrote in message
news:opsh9x9z1m x13kvk@atlantis ...
On Tue, 30 Nov 2004 10:19:39 GMT, McKirahan <Ne**@McKirahan .com> wrote:
"RobB" <fe******@hotma il.com> wrote in message
news:ab******** *************** ***@posting.goo gle.com...

[snip]
Hmm...what about those with JS disabled? Not much help...


[snip]

Well, it was asked in a JS group which begs for a JS solution.


So? A document that uses Javascript should never fail just because that
*optional* technology is disabled. A controlled environment might give you
more freedom, but as far as the Web is concerned, client-side scripting
should be an enhancement only.

Mike

--
Michael Winter
Replace ".invalid" with ".uk" to reply by e-mail.


Got it! I didn't reflect on my solution's total dependence on JS.
Jul 23 '05 #17
Well, I customized the script with images and it's working well.

I have another question.

Is it possible to use the script again on the same page with another
ten images so that list one rotates its ten images, and the second
script rotates its ten imagea independently?

I've been experimenting with this with so-so results so far...
Jul 23 '05 #18
"Royal Denning" <ro***********@ hotmail.com> wrote in message
news:4e******** *************** ***@posting.goo gle.com...
Well, I customized the script with images and it's working well.

I have another question.

Is it possible to use the script again on the same page with another
ten images so that list one rotates its ten images, and the second
script rotates its ten imagea independently?

I've been experimenting with this with so-so results so far...


Copy and rename the function then call it.
Jul 23 '05 #19
"Richard Cornford" <Ri*****@litote s.demon.co.uk> wrote in message news:<co******* ************@ne ws.demon.co.uk> ...
RobB wrote:
<snip>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt d">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
lang="en">

<snip>
document.write(

'<style type="text/css">' ,
s.replace(/,$/, '') ,
'{visibility:hi dden;}' ,
'</style>'

);

<snip>

Currently there are no XHTML DOM implementations that support
document.write.

Richard.


Oops, busted. Miss it already. Here's another stab at it....

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt d">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>untitled </title>
<!-- DEMO ONLY -->
<base href="http://i.office.micros oft.com/i/0000/MR/" />
<!-- DEMO ONLY -->
<style type="text/css">

body {
font-size: 100%;
margin: 12px;
background: #456;
}
#container {
width: 468px;
margin: 10px auto;
}
#rotator1, #rotator2 {
float: left;
margin: 10px;
border-collapse: collapse;
border: 2px #fff dashed;
background: #fff;
}
#rotator1 td, #rotator2 td {
text-align: center;
padding: 3px;
margin: 0;
border: 1px #bbb dashed;
}
td a:link, td a:visited {
font: normal 60% "comic sans ms", sans-serif;
color: #000;
text-decoration: none;
}
td a:hover {
text-transform: uppercase;
}
td a img {
display: block;
padding: 0;
margin: 0;
border-width: 0;
}

</style>
<script type="text/javascript">
//<![CDATA[

/*************** *************** *************** */
var table_ids = [ 'rotator1' , 'rotator2' ];
/*************** *************** *************** */

var alldivs = document.getEle mentsByTagName( 'DIV');

function Rotator(table_i d)
{
this.table = document.getEle mentById(table_ id);
this.cells = this.table.getE lementsByTagNam e('TD');
this.ncells = this.cells.leng th;
this.pix = [];
this.txt = [];
this.hrefs = [];
this.idx_array = new Array(this.ncel ls);

function read()
{
var cell, n = 0;
while (cell = this.cells.item (n++))
{
this.pix.push(c ell.getElements ByTagName('IMG' )[0].src);
this.txt.push(c ell.getElements ByTagName('A')[0].lastChild.node Value);
this.hrefs.push (cell.getElemen tsByTagName('A' )[0].href);
} this.shuffle();
}
this.read = read;

function shuffle()
{
var idx, i, ind1, ind2, temp;
for (i = 0; i < this.ncells; ++i)
this.idx_array[i] = i;
for (i = 0; i < this.ncells; ++i)
{
ind1 = Math.floor(Math .random() * this.ncells);
ind2 = Math.floor(Math .random() * this.ncells);
temp = this.idx_array[ind1];
this.idx_array[ind1] = this.idx_array[ind2];
this.idx_array[ind2] = temp;
} this.write();
}
this.shuffle = shuffle;

function write()
{
var cell, el, idx, n = 0;
while (cell = this.cells.item (n))
{
idx = this.idx_array[n++];
cell.getElement sByTagName('IMG ')[0].src = this.pix[idx];
(el = cell.getElement sByTagName('A')[0]).lastChild.nod eValue =
this.txt[idx];
el.href = this.hrefs[idx];
} alldivs.item(0) .style.visibili ty = 'visible';
}
this.write = write;

this.read();
}

onload = function()
{
if (document.getEl ementById && document.create Element)
for (var i = 0; i < table_ids.lengt h; ++i)
new Rotator(table_i ds[i]);
}

/* demo only */
function dummy(link)
{
alert(link.href .toUpperCase(). match(/[^#]*$/));
return false;
}

//]]>
</script>
</head>
<body>
<div id="container" >
<script type="text/javascript">
//<![CDATA[
alldivs.item(0) .style.visibili ty = 'hidden';
//]]>
</script>
<table id="rotator1">
<tbody>
<tr>
<td><a href="#displays " onclick="return dummy(this)">
<img src="j0399/j0399836.gif" />displays</a></td>
<td><a href="#diskette " onclick="return dummy(this)">
<img src="j0323/j0323552.gif" />diskette</a></td>
</tr><tr>
<td><a href="#floppies " onclick="return dummy(this)">
<img src="j0233/j0233109.gif" />floppies</a></td>
<td><a href="#monitor" onclick="return dummy(this)">
<img src="j0316/j0316344.gif" />monitor</a></td>
</tr><tr>
<td><a href="#mouse" onclick="return dummy(this)">
<img src="j0382/j0382582.gif" />mouse</a></td>
<td><a href="#dishes" onclick="return dummy(this)">
<img src="j0237/j0237779.gif" />dishes</a></td>
</tr><tr>
<td><a href="#cams" onclick="return dummy(this)">
<img src="j0396/j0396846.gif" />cams</a></td>
<td><a href="#pcs" onclick="return dummy(this)">
<img src="j0399/j0399981.gif" />pcs</a></td>
</tr><tr>
<td><a href="#birds" onclick="return dummy(this)">
<img src="j0198/j0198718.gif" />birds</a></td>
<td><a href="#recycle" onclick="return dummy(this)">
<img src="j0323/j0323582.gif" />recycle</a></td>
</tr>
</tbody>
</table>

<table id="rotator2">
<tbody>
<tr>
<td><a href="#kitty" onclick="return dummy(this)">
<img src="j0326/j0326434.gif" />kitty</a></td>
<td><a href="#kite" onclick="return dummy(this)">
<img src="j0231/j0231947.gif" />kite</a></td>
</tr><tr>
<td><a href="#telescop e" onclick="return dummy(this)">
<img src="j0287/j0287221.gif" />telescope</a></td>
<td><a href="#keys" onclick="return dummy(this)">
<img src="j0287/j0287325.gif" />keys</a></td>
</tr><tr>
<td><a href="#earth" onclick="return dummy(this)">
<img src="j0400/j0400664.gif" />earth</a></td>
<td><a href="#choo-choo" onclick="return dummy(this)">
<img src="j0234/j0234231.gif" />choo-choo</a></td>
</tr><tr>
<td><a href="#bus" onclick="return dummy(this)">
<img src="j0395/j0395931.gif" />bus</a></td>
<td><a href="#bull" onclick="return dummy(this)">
<img src="j0318/j0318944.gif" />bull !</a></td>
</tr><tr>
<td><a href="#shot-put" onclick="return dummy(this)">
<img src="j0303/j0303464.gif" />shot-put</a></td>
<td><a href="#pointer" onclick="return dummy(this)">
<img src="j0281/j0281730.gif" />pointer</a></td>
</tr>
</tbody>
</table>
</div>
</body>
</html>
Jul 23 '05 #20

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
7737
by: Finn Newick | last post by:
By defining a style as follows: @media aural, handheld {td.layout {display:block;}} I'm hoping to linearise layout tables when viewed by screenreaders and handheld devices (it is also be in some selectable user preferences). This works as intended in Netscape 7 - all the cells stack vertically above each other nicely, but not in Internet Explorer 6 where the only display property that td will respond to seems to be 'none'.
8
4420
by: Jukka K. Korpela | last post by:
I just noticed that most browsers render <table border="1"><tr><td><p>foo</p></td></tr></table> the same way as <table border="1"><tr><td>foo</td></tr></table> That is, they ignore the p markup in the sense that they don't apply the normal default top and bottom margins. This is rather odd, especially
1
2646
by: Mark Carroll | last post by:
I can't get my table cells to not have a gap between them in IE. For example, with IE6SP1 I get a gap between the two red squares on http://www.chiark.greenend.org.uk/~markc/test/test.html instead of just seeing one red rectangle. The CSS in that case had width: 1px; margin: 0; padding: 0; border-width: 0; border-spacing: 0 What can I do to get the red squares nestled together in the table with no space in between? -- Mark
4
26211
by: N. Demos | last post by:
The following code renders as intended in IE (A TABLE, with cells of fixed width and height, inside of a DIV with fixed width and height and overflow set to hidden.) In Firefox, the table cells assume a narrower with than specified. If I comment out the width for the DIV, then the cells render with the correct width and height. Why is this happening? Thanks. Regards, N. Demos
0
1689
by: N. Demos | last post by:
I have a single row table with fixed dimensioned cells nested inside a fixed dimensioned div, which has overflow: hidden. The div's dimensions are such that It should only display the first two table cells. This all renders correctly in MSIE 6.x, but doesn't in Firefox. In Firefox, the cell widths are reduced so that all the cells are displayed within the div frame. I've played around with this: commenting out css properties to see if...
3
5915
by: N. Demos | last post by:
I have a single row table with fixed dimensioned cells nested inside a fixed dimensioned div, which has overflow: hidden. The div's dimensions are such that It should only display the first two table cells. This all renders correctly in MSIE 6.x, but doesn't in Firefox. In Firefox, the cell widths are reduced so that all the cells are displayed within the div frame. I've played around with this: commenting out css properties to see if...
5
36881
by: Richard Dixson | last post by:
I created a new C# web application. Basically all I am trying to do is create a table that consists of a few rows with two columns in each. And then to set those columns to text values from my code behind. However I am not able to do this at all, I am going about this wrong, I think and need guideance. If this was just straight HTML I would do this: <table> <tr><td>field 1</td><td>value 1 set by code behind</td></tr>
1
2927
by: RobG | last post by:
I'm trying to get table cells to clip content rather than wrapping. It has been suggested to use: td.clipped { width: 5em; overflow: hidden; white-space: nowrap; }
0
1327
by: JM | last post by:
I'm using VS2005 SP1. It seems to me, when I used VS2003, the IDE would only insert height and width attributes in table cells if you dragged to resize a cell. Now, with VS2005, I get the style attributes whenever I drop a control into a cell or add content, and it's ANNOYING. Does anybody know of a way to get designer to stop slapping style attributes in table cells?
2
3039
by: markszlazak | last post by:
I'm a relatively slow response of table cells changing their background color with mouseover/our in IE6 (Win 2K) but the response is fine (fast) in Firefox. Why? The code is below. Sorry about the length. <html> <head> <title>Rapid Blocking Interface</title> <style> .calendar {
0
9706
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9579
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10577
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10320
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9150
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7620
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6853
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5521
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
3820
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.