/    Sign up×
Community /Pin to ProfileBookmark

style border-collapse

Hello,

can someone help? How do I add a “border-collapse:collapse” modification in the script below? Thanks much!

[CODE]
// call function to draw calendar
drawCal(firstDay + 1, days, date, monthName, year)
}

function drawCal(firstDay, lastDate, date, monthName, year) {
// constant table settings
var headerHeight = 50 // height of the table’s header cell
var border = 2 // 3D height of table’s border
var cellspacing = 4 // width of table’s border
var headerColor = “midnightblue” // color of table’s header
var headerSize = “+3” // size of tables header font
var colWidth = 60 // width of columns in table
var dayCellHeight = 25 // height of cells containing days of the week
var dayColor = “darkblue” // color of font representing week days
var cellHeight = 40 // height of cells representing dates in the calendar
var todayColor = “red” // color specifying today’s date in the calendar
var timeColor = “purple” // color of font representing current time

// create basic table structure
var text = “” // initialize accumulative variable to empty string
text += ‘<CENTER>’
text += ‘<TABLE BORDER=’ + border + ‘ CELLSPACING=’ + cellspacing + ‘>’ // table settings
text += ‘<TH COLSPAN=7 HEIGHT=’ + headerHeight + ‘>’ // create table header cell
text += ‘<FONT COLOR=”‘ + headerColor + ‘” SIZE=’ + headerSize + ‘>’ // set font for table header
text += monthName + ‘ ‘ + year
text += ‘</FONT>’ // close table header’s font settings
text += ‘</TH>’ // close header cell

// variables to hold constant settings
var openCol = ‘<TD WIDTH=’ + colWidth + ‘ HEIGHT=’ + dayCellHeight + ‘>’
openCol += ‘<FONT COLOR=”‘ + dayColor + ‘”>’
var closeCol = ‘</FONT></TD>’
[/CODE]

to post a comment
JavaScript

0Be the first to comment 😎

×

Success!

Help @fagin spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.18,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...