PLEASE do NOT strip my credits out of your code. They are harmless. Unlike most sites, My credits do NOT show up on your visible page, there is no reason to remove them. If you make a derivative of my work, you may add your own credits, but leave mine in tact.

I apologize for being less attentive to people's questions than in the past. I hope to return to doing this at some time. But for now I need to think about what I want to do. This doesn't mean I am completely ignoring all questions, if I suspect there might be a bug in my code, or myspace has made some change effecting it, I will still dig in and research.

Saturday, March 10, 2007

MySpace Calendar Structure Styling Moving Div Import

[note: This block was re-written May 20 2007 to take advantage of new myspace Classes]

PseudoCode
1) Classify where possible, to narrow down the potential area effected by the code changes.
a) Find the closest point, where myspace allows the insertion of data.
b) Close out cells, rows and tables to get to the desired point to add in a Div
c) Create the Div
d) Re-open the same number of tables, rows, cells closed in (a)

2) Use style commands to make room in the area where you want to place your calendar. You can use relative positioning to move down the items in either the top left or top right of the page.

3) Use style to resize the calendar to fit in the new location

4) Use style to move the calendar to the new location.
Code to place calendar in Top Left Corner
<span class="off">BLOCK:1Insert Custom Class and Div</span>
</td></tr></table>
</td></tr></table>
<div class="myDclassFC">
<table style="display:none"><tr><td>
<table><tr><td>
<span class="off">!^End Classify Div Block^!</span>

<span class="off">! Style Block to Move/Format Calendar !</span>
<style>
{! BLOCK:2 !}
{! size calendar to fit in the left column !}
.myDclassFC table, .myDclassFC table table {width:300px !important;}
.myDclassFC table table td {width:100px !important}
.myDclassFC table table td.text {width:200px !important}
.myDclassFC table table table {width:100px !important;}

{! reverse above effect on comment space !}
.myDclassFC table.friendsComments, .myDclassFC table.friendsComments table {width:430px !important;}
.myDclassFC table.friendsComments table td, .myDclassFC table.friendsComments table table {width:100% !important}
.myDclassFC table.friendsComments table table td {width:0px !important}

{! BLOCK:3 !}
{! move down top left content to accommodate calendar !}
{! top px value and margin-bottom px values should BOTH be set to the expected height of your calendar. You will need to change this if your calendar grows !}
.profileInfo {position:relative; top:250px; margin-bottom:250px;}

{! BLOCK:4 !}
{! position calendar top left !}
.myDclassFC table {position:absolute; top:175px; _top:185; right:50%; margin-right:75px;}

{! BLOCK:5 !}
{! maintain position of other stuff effected by above !}
.mydclassfc table table, .mydclassfc table.friendspace,
.mydclassfc table.friendscomments
{position:relative !important; top:0px; left:0px; right:0px; margin:0px;}

{! BLOCK:6 !}
{! Style stuff to improve calendar appearance !}
{! because myspace did not line the header up well to start with, this looks better if you use table and cell background colors to form borders !}
.mydclassfc table {background-color:lightblue;}
.mydclassfc table table td {background-color:lightgreen}
.mydclassfc table table table, .mydclassfc table table table td {background-color:yellow;}
</style>
<span class="off">!^End Style Block to Move/Format Calendar^!</span>

Remember to adjust px sizes to accommodate your own calendar length and profile.
The same concept is used to move the calendar to the top right. Instead of moving down the profileInfo, you would move down the item in your top right corner. In the default profile this is the extendedNetwork (or the video slider if you have chosen that option).

The below blocks are replacements for pieces of the above code. They go between style tags, and replace a similar block in the above code.

Replace [Block 3]code which makes room, for the calendar, in the top left; with code which makes room in Top Right
{! BLOCK 3 !}
{!move extended network down to make room for calendar!}
.extendedNetwork {position:relative; top:300px; margin-bottom:300px;}
OR
{! BLOCK 3!}
{!move video slider down to make room for calendar!}
td.text object, td.text embed {position:relative; top:300px; margin-bottom:300px;}
{!undo effect on any objects in your blurbs!}
td.text table.blurbs object, td.text table.blurbs embed {position:static}
AND
Replace [BLOCK 4]Code which relocates calendar to top Left, with code to relocate calendar to Top Right:
{! BLOCK 4!}
{!position calendar top right!}
.mydclassfc table {position:absolute; left:50%; top:175px; margin-left:-50px;}

OR if you want to locate the calendar between the contact table and the url box:
Replace [BLOCK 3] AND [BLOCK 4] with this:
{! BLOCK 3 !}
.contactTable {margin-bottom:300px;}
{! BLOCK 4 !}
{! position calendar after contact box on left !}
.myDclassFC table {position:absolute; top:510px; _top:515; right:50%; margin-right:75px;}
This is dependent on a static size of the ProfileInfo area in the top left. You do control this size via your content, and can control it further by assigning a height to the .ProfileInfo class.

The calendar resizing block [Block 2] can be omitted if you choose to locate the calendar top right. You may choose to keep this block and modify the values. This does give you more control over how the calendar looks. It has a tendency to resize weird if anything related to its position and/or size are changed, unless you hard-set the values (as I have done above).

The formatting block [Block 6] should be modified to your tastes. Look at how it effects your calendar, if used as coded. From there you will see which colors you want to change to suit your own profile. I used color names (instead of numbers) so you can easily see which area is effected by which color.

myspace codes to move the calendar (Well I have always just called it code, but the use of this word with plurality seems to be coming more and more common.)

Thank you for Visiting; Have a Nice Day :-)


-I have myspace calendar codes.

Labels:

10 Comments:

Anonymous RockStarNewYork said...

How do I remove certain events that show up on my page's calendar, but are nowhere to be found in the "manage calendar" section? Where did they go? Why can't I delete them?

(See myspace.com/rockstarnewyork and look at the "EAT LOT'S OF BIRD" for an example.)

17/9/07 19:02  
Anonymous daniel said...

HOW CAN I CHANGE THE COLOUR OF THE TEXT& dates in the calendar at myspace??

Thanks
www.myspace.com/electropaparazzi

21/10/07 04:08  
Blogger Eileen (aka Coboble) said...

Daniel,

Thank you for asking, I hadn't realized I failed to cover that in my article

I will add it to the article soon.

For now here is the code:

table table td.text table td font {color:hotpink !important}

The above effects the date and the location and the parentheses around the "view all" link.
It may effect the description depending on what other style you have for this.

You can style the description with this:

table table td.text table td font a {color:darkgreen !important;}

Make sure you put the commands in a style block.

Click Here to see an example of a style block

21/10/07 12:33  
Anonymous truedezign said...

This is Awesome information!!!

ONE QUICK DIFFICULT QUESTION!

How do I place a div around the calendar AND place a div around the FriendSpace/Comments so that they can both be moved around the page?

10/1/08 11:09  
Blogger Lookhappy said...

Hi again,
I'm having trouble hiding the calender - the client wants to still update her calender but for it to not show onscreen
http://www.myspace.com/distresstoimpress

I've tried a few different things but they just seem to move it.
Any help would be hugely appreciated

Thanks
Joe

8/4/08 05:16  
Blogger Eileen said...

You don't use code to hide the calendar.
You do this in set up.

Under Manage Calendar on your homepage, you will find an Options link. click that and then look for the calendar sharing option.
Set this to Disabled.

When I do this the calendar does not show up on my page.

8/4/08 07:32  
Blogger Team Thesaurus said...

Hi, I was trying to copy this into my band profile and couldn't get it to work...any hints on what I can change to get the calendar visible on my music page...preferably beneath or above the music player on the right...I know events will show...but I just want to list gigs I'm attending from my calendar.

http://www.myspace.com/jamesearthenware

Any tips would be greatly appreciated!! Thankyou.

15/5/08 22:45  
Anonymous Anonymous said...

when i try to hide the table header for my calendar, it only hides half of the light blue section. i have tried changing the values in the code. but it only makes it worse.


how can i not just hide, but take out that top calendar table row?

28/5/08 08:49  
Anonymous Joseph said...

Hi!! Great tutorials!! Is there a way to control the height of the calendar? Because if I add 15 events... the calendar is super long!.. perhaps there is a way to control it with overflow:scroll or somethin without messin up the friends/comments area! Help!!

29/8/08 21:06  
Blogger melissa said...

how do i make the width of my calendar smaller?

7/9/08 14:32  

Post a Comment

Links to this post:

Create a Link

<< Home