Pages

Showing posts with label webs. Show all posts
Showing posts with label webs. Show all posts

Friday, December 10, 2010

Added javascript toggle for the edit/create even dialog.


Javascript can be used to access document elements by ID on the client. In this
case we can toggle the visibility of the #editeventform using the css display
property.



http://rileyrg.imgur.com/pub_web_software/NQnSu



--
My Emacs Files At GitHub

Monday, December 6, 2010

Settings can be visible.


Particularly useful for things like web settings for comms path eg phone, email, fx etc. Token is the access id, title is human readable heading (can be internationalised) and description holds the value (again can be different for each language).

Visible Settings

Tuesday, November 30, 2010

Meta data and general settings unified into internationalised event UI

keywords META tag as a setting in the event list



Which means you can edit as any other event and internationalise accordingly.





function getPageMetaHTML($category)
{
$sql='select id from events where token="meta" and fenabled=1 and category="'.$category.'"';
if(($result=getDB()->query($sql))==false)
return "";

if($result->num_rows==0){
if($category!="index"){
return getPageMetaHTML("index");
}else
return "";
}
$res="";
while($r=$result->fetch_assoc()){
getEventLocaleFields(&$r);
$res.='<meta name="'.$r{"title"}.'" content="'.$r{"event"}.'">';
}
return $res;
}




--
My Emacs Files At GitHub

Friday, November 12, 2010

Enabling/Disabling events for Social Network sharing.


Enabling sharing example.



The create new/edit dialog now includes the ability to toggle event
sharing. This would typically be used to disable sharing for an item which can
not stand on its own such as a list item - some support text to an item that
includes an embedded object like a gcalendar or twitter feed for example. Or
perhaps simply something you dont want shared! Typically used in conjuntion with
the orderby field which is, currently, the only crude way to order things
(outside of caelendar ordering) in an event list in order to ensure certains
items remain at the top or bottom or follow a previous item. Relative ordering
and grouping is in the pipeline - this will facilitate online menu construction
and perhaps photo album management although I am doubtful that anything I
shoehorn in there can in any shape or form approach the functionality provided
by the plethora of existing solutions for photo management. Its what links are
for …



Event In German



As an added bonus it will now also allow you to share in another language. Just
set the language on the web page before sharing and the link back will ensure
that the article/event is in that language when people click back.



--
My Emacs Files At GitHub

Tuesday, November 2, 2010

Webs now using mssqli and simplified css layout


The Shamrock Irish Bar, Hamburg



Inspiration Yachts



Steve Fairway Music


--
My Emacs Files At GitHub

Moved from mysql functions mysqli class.


@mysql function calls pretty much deprecated in php. Moved all the code to
mysqli based. Pretty straightforward. e.g



$f=@fopen("authinfo","r",true);
$auth=explode(" ",@fgets($f));
@fclose($f);
setDB($mysqli = new mysqli($auth{3},$auth{0},$auth{1},$auth{2}));
if ($mysqli->connecterror) {
die('Connect Error (' . $mysqli->connecterrno . ') '
. $mysqli->connecterror);
}


--
My Emacs Files At GitHub

Friday, October 22, 2010

db update scripts

-- move all text into msgcodes
-- insert into msgcodes (id,lang_id,msgtext) select concat(id,"-event"),1,event from events;
-- insert into msgcodes (id,lang_id,msgtext) select concat(id,"-title"),1,title from events;
-- alter table events drop title;
-- alter table events drop event;

-- added code field to languages to hold two letter language code
alter table languages drop column code;
alter table languages add column code char(2) after id;
update languages set code=lcase(substring(language FROM 1 FOR 2));
alter table msgcodes change id id varchar(32);
alter table languages drop column field;
alter table msgcodes add column field varchar(32) after lang_id;
alter table msgcodes drop column fkey;
alter table msgcodes add column fkey int(10) unsigned after lang_id;
alter table msgcodes ENGINE = InnoDB;
alter table events ENGINE = InnoDB;
update msgcodes set fkey=SUBSTRING_INDEX(id,"-",1) where id REGEXP '^[0-9]+-';
update msgcodes set field=SUBSTRING_INDEX(id,"-",-1) where id REGEXP '^[0-9]+-';
alter table msgcodes add constraint deletecodes foreign key (fkey) references events (id) on delete cascade;






~/webs/db-update.sql::– move all text into msgcodes



--
My Emacs Files At GitHub

Wednesday, October 13, 2010

Drop down menus live from mySQL using CSS


I was preparing to entire the hazy horrible world of Java script to provide
event links from the navigation toolbar. And then! Bing! Why not use CSS? And it
works. Super. Click on the annoying advert below to take a gander …





MyUpload.org



--
My Emacs Files At GitHub

Saturday, October 2, 2010

Thursday, September 16, 2010