Buggy, be aware of the MySQL bug using Joomla 1.5.xx series (previous). As version 1.6 is too new and some extension has not been ported yet .
I'm running it locally, just playing with it , using latest XAMPP and I've to edit manually the db named 'joomla.sql' into the 'installation' directory to make it run properly
(also have to edit the php.ini file, but if you're using a remote host...)
Anyway, 1.6 seems better than 1.5.xx...
Best of lucks with it!
content management [i think] newbie questions?
meh, i'm just gonna do a really professional, clean standard site, hand-coded for efficiency, same as usual
2 menus for enhanced navigation within sections - there's like 20+ departments and some of them have multiple pages within - so departments in the main menu down the left, pages within departments in a small menu to the right
for the emergency warnings i'm going to write a log-in form page that just generates [and clears] a file for a php include - much simpler than anything i've seen in a cms, no sql either
cheaper and faster too
if they don't like it, fuck 'em, plus the form will be another thing i can use elsewhere, and i'll actually enjoy what i'm doing, as i usually do . . .
2 menus for enhanced navigation within sections - there's like 20+ departments and some of them have multiple pages within - so departments in the main menu down the left, pages within departments in a small menu to the right
for the emergency warnings i'm going to write a log-in form page that just generates [and clears] a file for a php include - much simpler than anything i've seen in a cms, no sql either
cheaper and faster too
if they don't like it, fuck 'em, plus the form will be another thing i can use elsewhere, and i'll actually enjoy what i'm doing, as i usually do . . .
update:
have wound up writing two mini cms's for two different websites, both using text files for storage
my next move is to try and figure out how forums such as this one get the markup buttons to work - assuming javascript is involved somehow
don't want to deal with the whole phpbb massive, plus for my clients i think a wysiwyg like vbulletin is better
wondering if just the input part might be floating loose somewhere . . .
have wound up writing two mini cms's for two different websites, both using text files for storage
my next move is to try and figure out how forums such as this one get the markup buttons to work - assuming javascript is involved somehow
don't want to deal with the whole phpbb massive, plus for my clients i think a wysiwyg like vbulletin is better
wondering if just the input part might be floating loose somewhere . . .
i've done similar here and elsewhere, but am not too sharp on javascriptnoryb009 wrote:Post reply -> right click background -> source -> search for bbstyle functionmy next move is to try and figure out how forums such as this one get the markup buttons to work
so the markup buttons can be made without the use of an installed system?
that would certainly make things easier
[edit]
oh, i think it's all starting to make a little more sense to me, despite the early hour and not sleeping in two weeks . . .
thanks!
[re-edit]
so it seems like it's basically javascript makes buttons, buttons cause javascript to add tags to selected [javascript is told what's selected] text, form [which for wysiwyg cannot be standard textarea so is also javascript somehow?] shows results?
once i hit submit and am sending the result back to php-land i'll feel a lot safer
[building an automobile out of scrap wood]
Step 1) Add the button. Add this HTML
#########################
<input type="button" class="button" name="addbbcode#" value=" Word(s) on button " style="width: ???px" onclick="bbstyle(#)">
#########################
For example:
#########################
<input type="button" class="button" name="addbbcode0" value=" B " style="font-weight:bold; width: 30px" onclick="bbstyle(0)">
#########################
Step 2) Add javascript
#########################
bbcode = new Array();
bbtags = new Array('','','','','[ect]','[/ect]');
imageTag = false;
var clientPC = navigator.userAgent.toLowerCase(); // Get client info
var clientVer = parseInt(navigator.appVersion); // Get browser version
var is_ie = ((clientPC.indexOf("msie") != -1) && (clientPC.indexOf("opera") == -1));
var is_nav = ((clientPC.indexOf('mozilla')!=-1) && (clientPC.indexOf('spoofer')==-1)
&& (clientPC.indexOf('compatible') == -1) && (clientPC.indexOf('opera')==-1)
&& (clientPC.indexOf('webtv')==-1) && (clientPC.indexOf('hotjava')==-1));
var is_moz = 0;
var is_win = ((clientPC.indexOf("win")!=-1) || (clientPC.indexOf("16bit") != -1));
var is_mac = (clientPC.indexOf("mac")!=-1);
function bbstyle(bbnumber) {
var txtarea = document.TheTextareaEitherByNameOrId;
txtarea.focus();
donotinsert = false;
theSelection = false;
bblast = 0;
if (bbnumber == -1) { // Close all open tags & default button names
while (bbcode[0]) {
butnumber = arraypop(bbcode) - 1;
txtarea.value += bbtags[butnumber + 1];
buttext = eval('document.getElementsByName("addbbcode' + butnumber + '")[0].value');
eval('document.getElementsByName("addbbcode' + butnumber + '")[0].value ="' + buttext.substr(0,(buttext.length - 1)) + '"');
}
imageTag = false; // All tags are closed including image tags
txtarea.focus();
return;
}
if ((clientVer >= 4) && is_ie && is_win)
{
theSelection = document.selection.createRange().text; // Get text selection
if (theSelection) {
// Add tags around selection
document.selection.createRange().text = bbtags[bbnumber] + theSelection + bbtags[bbnumber+1];
txtarea.focus();
theSelection = '';
return;
}
}
else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
{
mozWrap(txtarea, bbtags[bbnumber], bbtags[bbnumber+1]);
return;
}
// Find last occurance of an open tag the same as the one just clicked
for (i = 0; i < bbcode.length; i++) {
if (bbcode == bbnumber+1) {
bblast = i;
donotinsert = true;
}
}
if (donotinsert) { // Close all open tags up to the one just clicked & default button names
while (bbcode[bblast]) {
butnumber = arraypop(bbcode) - 1;
txtarea.value += bbtags[butnumber + 1];
buttext = eval('document.getElementsByName("addbbcode' + butnumber + '")[0].value');
eval('document.getElementsByName("addbbcode' + butnumber + '")[0].value ="' + buttext.substr(0,(buttext.length - 1)) + '"');
imageTag = false;
}
txtarea.focus();
return;
} else { // Open tags
if (imageTag && (bbnumber != #OFIMAGETAG!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!)) { // Close image tag before adding another
txtarea.value += bbtags[#OFIMAGETAG+1];
lastValue = arraypop(bbcode) - 1; // Remove the close image tag from the list
document.post.addbbcode#OFIMAGETAG.value = "TEXT ON IMAGE BUTTON"; // Return button back to normal state
imageTag = false;
}
// Open tag
txtarea.value += bbtags[bbnumber];
if ((bbnumber == #OFIMAGETAG) && (imageTag == false)) imageTag = 1; // Check to stop additional tags after an unclosed image tag
arraypush(bbcode,bbnumber+1);
eval('document.post.addbbcode'+bbnumber+'.value += "*"');
txtarea.focus();
return;
}
storeCaret(txtarea);
}
#########################
There might be a few errors, I haven't tested it.
#########################
<input type="button" class="button" name="addbbcode#" value=" Word(s) on button " style="width: ???px" onclick="bbstyle(#)">
#########################
For example:
#########################
<input type="button" class="button" name="addbbcode0" value=" B " style="font-weight:bold; width: 30px" onclick="bbstyle(0)">
#########################
Step 2) Add javascript
#########################
bbcode = new Array();
bbtags = new Array('','','','','[ect]','[/ect]');
imageTag = false;
var clientPC = navigator.userAgent.toLowerCase(); // Get client info
var clientVer = parseInt(navigator.appVersion); // Get browser version
var is_ie = ((clientPC.indexOf("msie") != -1) && (clientPC.indexOf("opera") == -1));
var is_nav = ((clientPC.indexOf('mozilla')!=-1) && (clientPC.indexOf('spoofer')==-1)
&& (clientPC.indexOf('compatible') == -1) && (clientPC.indexOf('opera')==-1)
&& (clientPC.indexOf('webtv')==-1) && (clientPC.indexOf('hotjava')==-1));
var is_moz = 0;
var is_win = ((clientPC.indexOf("win")!=-1) || (clientPC.indexOf("16bit") != -1));
var is_mac = (clientPC.indexOf("mac")!=-1);
function bbstyle(bbnumber) {
var txtarea = document.TheTextareaEitherByNameOrId;
txtarea.focus();
donotinsert = false;
theSelection = false;
bblast = 0;
if (bbnumber == -1) { // Close all open tags & default button names
while (bbcode[0]) {
butnumber = arraypop(bbcode) - 1;
txtarea.value += bbtags[butnumber + 1];
buttext = eval('document.getElementsByName("addbbcode' + butnumber + '")[0].value');
eval('document.getElementsByName("addbbcode' + butnumber + '")[0].value ="' + buttext.substr(0,(buttext.length - 1)) + '"');
}
imageTag = false; // All tags are closed including image tags
txtarea.focus();
return;
}
if ((clientVer >= 4) && is_ie && is_win)
{
theSelection = document.selection.createRange().text; // Get text selection
if (theSelection) {
// Add tags around selection
document.selection.createRange().text = bbtags[bbnumber] + theSelection + bbtags[bbnumber+1];
txtarea.focus();
theSelection = '';
return;
}
}
else if (txtarea.selectionEnd && (txtarea.selectionEnd - txtarea.selectionStart > 0))
{
mozWrap(txtarea, bbtags[bbnumber], bbtags[bbnumber+1]);
return;
}
// Find last occurance of an open tag the same as the one just clicked
for (i = 0; i < bbcode.length; i++) {
if (bbcode == bbnumber+1) {
bblast = i;
donotinsert = true;
}
}
if (donotinsert) { // Close all open tags up to the one just clicked & default button names
while (bbcode[bblast]) {
butnumber = arraypop(bbcode) - 1;
txtarea.value += bbtags[butnumber + 1];
buttext = eval('document.getElementsByName("addbbcode' + butnumber + '")[0].value');
eval('document.getElementsByName("addbbcode' + butnumber + '")[0].value ="' + buttext.substr(0,(buttext.length - 1)) + '"');
imageTag = false;
}
txtarea.focus();
return;
} else { // Open tags
if (imageTag && (bbnumber != #OFIMAGETAG!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!)) { // Close image tag before adding another
txtarea.value += bbtags[#OFIMAGETAG+1];
lastValue = arraypop(bbcode) - 1; // Remove the close image tag from the list
document.post.addbbcode#OFIMAGETAG.value = "TEXT ON IMAGE BUTTON"; // Return button back to normal state
imageTag = false;
}
// Open tag
txtarea.value += bbtags[bbnumber];
if ((bbnumber == #OFIMAGETAG) && (imageTag == false)) imageTag = 1; // Check to stop additional tags after an unclosed image tag
arraypush(bbcode,bbnumber+1);
eval('document.post.addbbcode'+bbnumber+'.value += "*"');
txtarea.focus();
return;
}
storeCaret(txtarea);
}
#########################
There might be a few errors, I haven't tested it.
i appreciate all that, and will give 'er a go, but it is someone else's code, and i can already tell that it does things i do not need it to do [os/browser detect, they all use win/ie at the office], while at the same time not helping me understand the basic processes of the thing
and i'm not seeing bold() and whatever the <a> javascript function is -- i think i read somewhere that you can create functions in javascript, so i could make them that did classes and ids for css?
[whiney, whiney little bitch that i am]
however, i am pleased to see <input type="button"> as i had not heard of this before; the old wdg html reference i tend to use does not have much detail when it comes to the input tag, and of course does not mention that it can be used as a trigger for javascript events
sorry if i'm asking stupid questions; i've spent the last week learning enough php to build two different content systems -- one with a control panel -- and now having to start learning enough javascript to enable/simplify markup [i have a weird markup system -- markup-defined fields -- for the one system but the other system is writing to pages previously done in <pre> so none needed] is making me a bit crazier than normal, especially as i should be learning arrays to simplify my slightly clunky programming [3500 bytes to process, markup and store 22 fields of text/area could be under a thousand?]
and capable of atrocious paragraphs to boot [swapping out syntax disabilities]
i suppose it might help to know that i am one of those people who can only learn by doing a thing -- and who only wants to know what i need to know [sherlock holmes, the earth and sun revolving?] -- and can only do what i understand, that is, despite my limited knowledge of php i have hand-written oodles of it this week and can explain in english what each bit of it means and how it works -- i do not use comment lines
i've got to go feed cats, and work on my proposal, and do some serious talking to myself [one of my forms of meditation/thinking/learning] about javascript, the language that dare not speak its name . . .
[lobster, can i borrow your loopy smiley?]
and i'm not seeing bold() and whatever the <a> javascript function is -- i think i read somewhere that you can create functions in javascript, so i could make them that did classes and ids for css?
[whiney, whiney little bitch that i am]
however, i am pleased to see <input type="button"> as i had not heard of this before; the old wdg html reference i tend to use does not have much detail when it comes to the input tag, and of course does not mention that it can be used as a trigger for javascript events
sorry if i'm asking stupid questions; i've spent the last week learning enough php to build two different content systems -- one with a control panel -- and now having to start learning enough javascript to enable/simplify markup [i have a weird markup system -- markup-defined fields -- for the one system but the other system is writing to pages previously done in <pre> so none needed] is making me a bit crazier than normal, especially as i should be learning arrays to simplify my slightly clunky programming [3500 bytes to process, markup and store 22 fields of text/area could be under a thousand?]
and capable of atrocious paragraphs to boot [swapping out syntax disabilities]
i suppose it might help to know that i am one of those people who can only learn by doing a thing -- and who only wants to know what i need to know [sherlock holmes, the earth and sun revolving?] -- and can only do what i understand, that is, despite my limited knowledge of php i have hand-written oodles of it this week and can explain in english what each bit of it means and how it works -- i do not use comment lines
i've got to go feed cats, and work on my proposal, and do some serious talking to myself [one of my forms of meditation/thinking/learning] about javascript, the language that dare not speak its name . . .
[lobster, can i borrow your loopy smiley?]
This is much simpler version of the above script. It just adds the text to the end of the textarea:
#######################
<input type="button" value="Bold" onclick="document.getElementById('textarea').value += '[b]'">
<input type="button" value="End Bold" onclick="document.getElementById('textarea').value += '[/b]'">
ect.
<textarea name="textarea" id="textarea"></textarea>
#######################
Then in the PHP code:
#######################
<?php
$textareaText = $REQUEST['textarea'];
$textareaText = preg_replace(array("/\[b\]/","/\[\/b\]/"),
array("<b>","</b>"),
$textareaText);
echo $textareaText;
?>
#######################
first array is ,"/\[codeorwhateverisinbrackets\]/","/\[\/codeorwhateverisinbrackets\]/")
second array is ,"<htmlcode>","</htmlcode>"
#######################
<input type="button" value="Bold" onclick="document.getElementById('textarea').value += '[b]'">
<input type="button" value="End Bold" onclick="document.getElementById('textarea').value += '[/b]'">
ect.
<textarea name="textarea" id="textarea"></textarea>
#######################
Then in the PHP code:
#######################
<?php
$textareaText = $REQUEST['textarea'];
$textareaText = preg_replace(array("/\[b\]/","/\[\/b\]/"),
array("<b>","</b>"),
$textareaText);
echo $textareaText;
?>
#######################
first array is ,"/\[codeorwhateverisinbrackets\]/","/\[\/codeorwhateverisinbrackets\]/")
second array is ,"<htmlcode>","</htmlcode>"
[url=https://github.com/noryb009/lick/releases/latest]LICK - Install Puppy Linux from Windows[/url]