Subject:*
<
Name/Email:*
<
Message Icon:*
<
Select*
<
Message:*
<



Click the Preview to see the content in action.
Options:*
<
Confirmation Code*
<
5 + 8 = ?  
Input the result from the expression
Maximum attempts you can try: 10
*
<
     

Re: The need for content management
by Grover on 2005/9/20 17:03:05

Well that didn't work and even if it had I'm not exactly comfortable with the need to add JavaScript statements to the theme head tag every time I need to use a bit of JavaScript. Once or twice might be okay but what if, over time, I need a couple hundred different JavaScript statements? The idea behind using a CMS is to speedily add content to a site. All this hacking seems to defeat that purpose.

What I think I understand is that, even in a module such as Tiny D or WF Sections that purports to "wrap" HTML documents inside of Xoops, this is going on: The head tag in the imported document is being ignored and the head tag of the theme is being used. Is there any way to force XOOPS to use the head tag from the imported document instead?

Beyond that I think I need to look at using pop-ups to access outside documents for this kind of content. That would require a one-time hack only. Alternatively, I should look at building these kind of interactive apps in flash or shockwave. Any thoughts? Comments?

Firefox users only account for 5% of my traffic but no doubt that will grow. It's definitely a concern. I've also had problems displaying flash correctly in the whole family of Mozilla browsers.
Re: The need for content management
by JMorris on 2005/9/20 1:45:53

At first glance, I believe the problem is that you don't have the javascript included in your theme header. When I viewed the source of the working page, I found the following between the head tags:

Style elements that need to be moved to your theme's style.css:

le="color: #000000"><?php <style type="text/css"> <!-- .tooltiptitle{COLOR: #FFFFFF; TEXT-DECORATION: none; CURSOR: Default; font-family: sans-serif; font-weight: bold; font-size: 8pt} .tooltipcontent{COLOR: #000000; TEXT-DECORATION: none; CURSOR: Default; font-family: sans-serif; font-size: 8pt} #ToolTip{position:absolute; width: 100px; top: 0px; left: 0px; z-index:4; visibility:hidden;} --> </style>


Javascript elements that need to be moved inside the <head></head> tags of your theme.html:

le="color: #000000"><?php <script language = "javascript"> <!-- var ie = document.all ? 1 : 0 var ns = document.layers ? 1 : 0 if(ns){doc = "document."; sty = ""} if(ie){doc = "document.all."; sty = ".style"} var initialize = 0 var Ex, Ey, topColor, subColor, ContentInfo if(ie){ Ex = "event.x" Ey = "event.y" topColor = "#000000" subColor = "#FFFFCC" } if(ns){ Ex = "e.pageX" Ey = "e.pageY" window.captureEvents(Event.MOUSEMOVE) window.onmousemove=overhere topColor = "#000000" subColor = "#FFFFCC" } function MoveToolTip(layerName, FromTop, FromLeft, e){ if(ie){eval(doc + layerName + sty + ".top = " + (eval(FromTop) + document.body.scrollTop))} if(ns){eval(doc + layerName + sty + ".top = " + eval(FromTop))} eval(doc + layerName + sty + ".left = " + (eval(FromLeft) + 15)) } function ReplaceContent(layerName){ if(ie){document.all[layerName].innerHTML = ContentInfo} if(ns){ with(document.layers[layerName].document) { open(); write(ContentInfo); close(); } } } function Activate(){initialize=1} function deActivate(){initialize=0} function overhere(e){ if(initialize){ MoveToolTip("ToolTip", Ey, Ex, e) eval(doc + "ToolTip" + sty + ".visibility = 'visible'") } else{ MoveToolTip("ToolTip", 0, 0) eval(doc + "ToolTip" + sty + ".visibility = 'hidden'") } } function EnterContent(layerName, TTitle, TContent){ ContentInfo = '<table border="0" width="200" cellspacing="0" cellpadding="0">'+ '<tr><td width="100%" bgcolor="#000000">'+ '<table border="0" width="100%" cellspacing="1" cellpadding="0">'+ '<tr><td width="100%" bgcolor='+topColor+'>'+ '<table border="0" width="90%" cellspacing="0" cellpadding="0" align="center">'+ '<tr><td width="100%">'+ '<font class="tooltiptitle">&nbsp;'+TTitle+'</font>'+ '</td></tr>'+ '</table>'+ '</td></tr>'+ '<tr><td width="100%" bgcolor='+subColor+'>'+ '<table border="0" width="90%" cellpadding="0" cellspacing="1" align="center">'+ '<tr><td width="100%">'+ '<font class="tooltipcontent">'+TContent+'</font>'+ '</td></tr>'+ '</table>'+ '</td></tr>'+ '</table>'+ '</td></tr>'+ '</table>'; ReplaceContent(layerName) } //--> </script>


Once you put those codes in the right place, your block code *should* work.

BTW, the javascript doesn't work with Firefox.

Hope this helps.

James
Re: The need for content management
by Grover on 2005/9/20 1:22:03

Thanks James. I think I understand no why the tables wouldn't work. I'm guessing that the cell padding/spacing are being disabled with the Theme CSS. That's why you needed to include the style="padding:1px;" with the TD tag. I tried it out and it works like a charm.

On the other hand, I still can't get the JavaScript to function correctly. Check Here and mouse over the stars. ToolTips are supposed to pop up at the cursor but instead I get very erratic behaviour. This is how it is supposed to look: Same code outside of Xoops. Any ideas?
Re: The need for content management
by JMorris on 2005/9/19 17:54:26

Quote:
First I tried a custom block but that didn't allow tables.


Here are some examples of using custom code in custom blocks. All of these examples work with the XOOPS native block manager. So, in a sense, there is native content management functionality in XOOPS (all versions), but only basic.

HTML example (Set Content Type to HTML):
le="color: #000000"><?php <center> <table cellspacing="0" cellpadding="0"> <tr> <td valign="middle" align="center" style="padding:1px;"><a href='http://www.silktide.com/report.php?url=http%3A%2F%2Fmywebresource.com' rel="nofollow"><img src='http://sitescore.silktide.com/index.php?siteScoreUrl=http%3A%2F%2Fmywebresource.com' alt='Silktide SiteScore for this website' border='0' /></a></td> </tr> <tr> <td valign="middle" align="center" style="padding:1px;"><a href="http://www.xoops-topsites.com/in.php?id=359" rel="nofollow"><img src="http://www.xoops-topsites.com/button.php?id=359" alt="" /></a></td> </tr> <tr> <td valign="middle" align="center" style="padding:1px;"><a href="http://www.321webmaster.com/index.php?in=16645" target="_blank" rel="nofollow"><img src="http://mywebresource.com/images/321webmaster.gif" width="88" height="31" alt="321Webmaster" border="0" align="bottom" /></a></td> </tr> <tr> <td valign="middle" align="center" style="padding:1px;"><a href="http://www.walshaw.com/topsites/index.php?ID=18" rel="nofollow"><img src="http://www.walshaw.com/images/wbutton1.gif" alt="" /></a><br /></td> </tr> <tr> <td valign="middle" align="center" style="padding:1px;"><a href="http://webmaster.itopsites.com/in.php?id=20508" rel="nofollow"><img src="http://webmaster.itopsites.com/button.php?id=20508" alt="" /></a></td> </tr> </table> </center>


Javascript example (Set Content Type to HTML):
le="color: #000000"><?php <center> <!--The following will create a cross browser compatible scrolling marquee in the page header. Follow the directions in the code to customize the marquee. Do not change the demensions of the marquee or the page layout will break.--> <script language="JavaScript1.2"> /* Cross browser Marquee script- © Dynamic Drive (http://www.dynamicdrive.com) For full source code, 100's more DHTML scripts, and Terms Of Use, visit http://www.dynamicdrive.com Credit MUST stay intact */ //Specify the marquee's width (in pixels) var marqueewidth="345px" //Specify the marquee's height var marqueeheight="16px" //Specify the marquee's marquee speed (larger is faster 1-10) var marqueespeed=2 //configure background color: var marqueebgcolor="#FFFFFF" //Pause marquee onMousever (0=no. 1=yes)? var pauseit=0 //Specify the marquee's content (don't delete <nobr> tag) //Keep all content on ONE line, and backslash any single quotations (ie: that's great): var marqueecontent='<nobr><font face="Arial"><a href="http://mywebresource.com/" target="_self">MyWebResource is a site dedicated to providing a centralized portal to aid visitors in finding and evaluating resources for their website. Click here to visit MyWebResource now!</a></font></nobr>' ////NO NEED TO EDIT BELOW THIS LINE//////////// marqueespeed=(document.all)? marqueespeed : Math.max(1, marqueespeed-1) //slow speed down by 1 for NS var copyspeed=marqueespeed var pausespeed=(pauseit==0)? copyspeed: 0 var iedom=document.all||document.getElementById if (iedom) document.write('<span id="temp" style="visibility:hidden;position:absolute;top:-100px;left:-9000px">'+marqueecontent+'</span>') var actualwidth='' var cross_marquee, ns_marquee function populate(){ if (iedom){ cross_marquee=document.getElementById? document.getElementById("iemarquee") : document.all.iemarquee cross_marquee.style.left=parseInt(marqueewidth)+8+"px" cross_marquee.innerHTML=marqueecontent actualwidth=document.all? temp.offsetWidth : document.getElementById("temp").offsetWidth } else if (document.layers){ ns_marquee=document.ns_marquee.document.ns_marquee2 ns_marquee.left=parseInt(marqueewidth)+8 ns_marquee.document.write(marqueecontent) ns_marquee.document.close() actualwidth=ns_marquee.document.width } lefttime=setInterval("scrollmarquee()",20) } window.onload=populate function scrollmarquee(){ if (iedom){ if (parseInt(cross_marquee.style.left)>(actualwidth*(-1)+8)) cross_marquee.style.left=parseInt(cross_marquee.style.left)-copyspeed+"px" else cross_marquee.style.left=parseInt(marqueewidth)+8+"px" } else if (document.layers){ if (ns_marquee.left>(actualwidth*(-1)+8)) ns_marquee.left-=copyspeed else ns_marquee.left=parseInt(marqueewidth)+8 } } if (iedom||document.layers){ with (document){ document.write('<table border="0" cellspacing="0" cellpadding="0"><td>') if (iedom){ write('<div style="position:relative;width:'+marqueewidth+';height:'+marqueeheight+';overflow:hidden">') write('<div style="position:absolute;width:'+marqueewidth+';height:'+marqueeheight+';background-color:'+marqueebgcolor+'" onMouseover="copyspeed=pausespeed" onMouseout="copyspeed=marqueespeed">') write('<div id="iemarquee" style="position:absolute;left:0px;top:0px"></div>') write('</div></div>') } else if (document.layers){ write('<ilayer width='+marqueewidth+' height='+marqueeheight+' name="ns_marquee" bgColor='+marqueebgcolor+'>') write('<layer name="ns_marquee2" left=0 top=0 onMouseover="copyspeed=pausespeed" onMouseout="copyspeed=marqueespeed"></layer>') write('</ilayer>') } document.write('</td></table>') } } </script> </center>


Macromedia Flash example (Set Content Type to HTML):
le="color: #000000"><?php <center> <OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" WIDTH="468" HEIGHT="60" id="XOOPSBanner"> <PARAM NAME=movie VALUE="banner.swf"> <PARAM NAME=quality VALUE=high> <PARAM NAME=bgcolor VALUE=#FFFFFF> <EMBED src="/images/banners/banner.swf" quality=high bgcolor=#FFFFFF WIDTH="468" HEIGHT="60" NAME="XOOPSBanner" ALIGN="" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"> </EMBED> </OBJECT> </center>


PHP Example (Set Content Type to PHP):
le="color: #000000"><?php <center> phpinfo(); </center>


As far as including an awesome content management module in the core goes... I really don't feel that this is in the best interest of XOOPS. If you remove competition entirely, then quality and features suffer. By outsourcing the responsibility of creating a top-notch content management module to third-party developers, the community benefits by having a selection of modules that meet different needs.

Granted, in your situation, none of the current modules meet your needs, but you are an exception. That's not to say that you shouldn't request the features you want. In fact, I'm sure the developers of the various content modules would welcome a feature request.

My suggestion is that you find the module(s) that comes closest to what you are looking for and contact the developer of that module.

Also, some of the content management modules for XOOPS have support for Kovi editor and HTML Area. Those plug-ins offer a tremendous amount of WYSIWYG editing features.

As far as custom coding specific code into your content goes, that's where custom blocks really shine! There is a tremendous amount of flexibility in what you can do with them if they are used correctly.

Hope this is helpful.

James
Re: The need for content management
by Grover on 2005/9/19 17:19:33

Thanks, JMorris, for the insights into how module development works.

Let me see if I can elucidate my dilemma a bit better. The problem is that I can usually find one module or another that will display my content but it's usually a hit and miss -- and very time-consuming -- proposition. Not to single out any module and trash it; that's not what this is about. Let me provide a few examples.

A while back I wanted to create a simple four column layout using a table with four photos across the top and cutlines across the bottom: simple static content that could be easily updated on a regular basis. First I tried a custom block but that didn't allow tables. Next I think I tried News and had some other problems but I can't remember offhand what they were. Then I tried WF Channel and it allowed for tables if I remember correctly but didn't allow for cell padding so the content was all jammed up together, one column jammed into the other with no breathing room. Finally I downloaded and installed Tiny D and it worked and it's still being used to display the content at the bottom of this page here: http://www.hima-ari.com. It's not like what I'm trying to do is really seriously challenging stuff. This is really basic yet it took an awful lot of work to get there. I cite this as a simple example for illustration purposes only and in no way am I attempting to belittle the efforts of any module developers.

Now for a more complex example:

Over two sites I have approaching 1500 pages of content in two different languages. Obviously I need something approaching reliability to manage all that.

Let's look only at the site mentioned above. I'm using XF Section for the bulk of the Japanese content and Articles for most of the English content. Say for instance I decided to put together a 10 part series on the ins and outs of studying English in Canada. I want it in Japanese for our primary readership and in English to demonstrate the content to potential advertisers.

So I decide to work on the English part first as it's easier for me to work in English. Say the first two entries are fairly straightforward, some text and graphics. Fine. So say I continue to use the Articles module to display them in. No problem so far and it connects up with all the other English content. Bonus! Then I need to add some shockwave content in the next installment. I can't remember if Articles works with shockwave or not but let's say it doesn't just for the sake of illustration. So I try something else out. Again just for illustration purposes let's say I get the shockwave working in WF Channel. That's a relief. So reluctantly I move the first three articles in this series over to WF Channel, tweak menus, tweak blocks and placement and then get down to the fourth article. Well this one requires some JavaScript. When all is said and done I can't get the JavaScript working without a lot of extra line breaks in WF Channel. So I try out something like Tiny D. Maybe it works. I don't know. I can't remember. I've been bouncing around between so many different so-called content management modules that I haven't a clue anymore which ones work with what. The point of all this being that none of them work with everything; not even close to everything. And because of that it's increasingly difficult to create any sense of continuity.

I understood what you were saying about the difference between CMS and CMF and, while I'm sure there are good reasons for taking that approach, from the point of view of content managers it sounds like a tragedy. From the point of view of operating a functional site and delivering content to end users it sounds like the cart is before the horse. Shouldn't the core be built around a kickass content module rather than like a doughnut with this gigantic hole in the middle?

Perhaps this sums up what is going on. XOOPS and a lot of these PHP portals are crucibles for honing and showcasing the skills of the developers. But the developers, not being content deliverers in the true sense of the phrase, are working in a vacuum, developing for imagined needs rather than real world ones. Ultimately, if the CMS/CMF can't really be put to work managing the complex needs of content delivery, then it fails as a showcase for the skills of those developers, doesn't it?

I certainly haven't decided to chuck it all as far as XOOPS is concerned but I'm very, very worried. I've invested an awful lot of energy and now I'm just starting to realize that perhaps XOOPS will never be able to meet my needs. Do I want to try another CMS? I'm certainly willing to take a second look. Should I go back to straight HTML, plunking in bits and pieces of PHP as appropriate? I'm not sure. I'm really not sure.

Who's Online

415 user(s) are online (363 user(s) are browsing Support Forums)


Members: 0


Guests: 415


more...

Donat-O-Meter

Stats
Goal: $15.00
Due Date: Jul 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $15.00
Make donations with PayPal!

Latest GitHub Commits