added: a new plugin: seo

new winix function: "seo", it allowes to edit subject, description and keywords for a page
description and keywords are stored in meta



git-svn-id: svn://ttmath.org/publicrep/winix/trunk@1179 e52654a7-88a9-db11-a3e9-0013d4bc506e
pull/3/head
Tomasz Sowa 4 years ago
parent eec8635af4
commit ab005118ba

@ -87,6 +87,7 @@ plugins: FORCE
@cd plugins/menu ; $(MAKE) -e
@cd plugins/export ; $(MAKE) -e
@cd plugins/mailregister ; $(MAKE) -e
@cd plugins/seo ; $(MAKE) -e
FORCE:
@ -106,6 +107,7 @@ clean:
@cd plugins/menu ; $(MAKE) -e clean
@cd plugins/export ; $(MAKE) -e clean
@cd plugins/mailregister ; $(MAKE) -e clean
@cd plugins/seo ; $(MAKE) -e clean
@cd $(GLOBAL_WORKING_DIR)/ezc/src ; $(MAKE) -e clean
@cd $(GLOBAL_WORKING_DIR)/tito/src ; $(MAKE) -e clean
@cd $(GLOBAL_WORKING_DIR)/pikotools ; $(MAKE) -e clean
@ -132,6 +134,7 @@ depend:
@cd plugins/menu ; $(MAKE) -e depend
@cd plugins/export ; $(MAKE) -e depend
@cd plugins/mailregister ; $(MAKE) -e depend
@cd plugins/seo ; $(MAKE) -e depend
@cd $(GLOBAL_WORKING_DIR)/ezc/src ; $(MAKE) -e depend
@cd $(GLOBAL_WORKING_DIR)/tito/src ; $(MAKE) -e depend
@cd $(GLOBAL_WORKING_DIR)/pikotools ; $(MAKE) -e depend

File diff suppressed because one or more lines are too long

@ -0,0 +1,32 @@
<div class="winix">
<h1>{seo_title}</h1>
<form method="post" action="[doc_base_url][dir][if item_is][item_url]/[end]seo">
<div class="winix_input_a">
<label for="winix_title_id">{title}:</label>
<input id="winix_title_id" type="text" name="subject" value="[item_subject]" autofocus>
</div>
<div class="winix_input_a">
<label for="winix_description_id">{seo_description}:</label>
<input id="winix_description_id" type="text" name="description" value="[item_meta "seo" "description"]">
</div>
<div class="winix_input_a">
<label for="winix_keywords_id">{seo_keywords}:</label>
<input id="winix_keywords_id" type="text" name="keywords" value="[item_meta "seo" "keywords"]">
</div>
[if winix_function_param_is "postredirect"]
<input type="hidden" name="postredirect" value="[winix_function_param_value "postredirect"]">
[end]
<input type="submit" value="{change}">
</form>
</div>

@ -30,6 +30,7 @@
[winix_function_is "reload"]
[winix_function_is "rm"]
[winix_function_is "rmuser"]
[winix_function_is "seo"]
[winix_function_is "sort"]
[winix_function_is "stat"]
[winix_function_is "subject"]

@ -617,6 +617,10 @@ tz_+13:00 = Nuku'alofa
tz_+13:00b = Samoa
seo_title = Seo
seo_description = Description
seo_keywords = Keywords

@ -635,6 +635,11 @@ tz_+13:00 = Nuku'alofa
tz_+13:00b = Samoa
seo_title = Seo
seo_description = "Opis (tag meta description)"
seo_keywords = "Słowa kluczowe (tag meta keywords)"

@ -0,0 +1,33 @@
include Makefile.o.dep
current_path := $(shell pwd)
global_relative_working_dir := $(shell relative_path $(current_path) $(GLOBAL_WORKING_DIR))
winix_include_paths = -I$(global_relative_working_dir)/winix/winixd -I$(global_relative_working_dir)/ezc/src -I$(global_relative_working_dir)/tito/src -I$(global_relative_working_dir)/morm/src -I$(global_relative_working_dir)/pikotools
name = seo.so
all: $(name)
$(name): $(o)
$(CXX) -shared -Wl,-soname,$(name) -o $(name) $(CXXFLAGS) $(winix_include_paths) $(LDFLAGS) *.o
%.o: %.cpp
$(CXX) -c $(CXXFLAGS) $(winix_include_paths) $<
depend:
makedepend -Y. $(winix_include_paths) -f- *.cpp > Makefile.dep
echo -n "o = " > Makefile.o.dep
ls -1 *.cpp | xargs -I foo echo -n foo " " | sed -E "s/([^\.]*)\.cpp[ ]/\1\.o/g" >> Makefile.o.dep
clean:
rm -f *.o
rm -f *.so
rm -f $(name)
include Makefile.dep

@ -0,0 +1,339 @@
# DO NOT DELETE
init.o: seo.h ../../../../winix/winixd/functions/functionbase.h
init.o: ../../../../winix/winixd/core/item.h
init.o: ../../../../pikotools/space/space.h
init.o: ../../../../pikotools/textstream/types.h
init.o: ../../../../pikotools/date/date.h
init.o: ../../../../pikotools/convert/inttostr.h
init.o: ../../../../winix/winixd/db/db.h ../../../../winix/winixd/db/dbbase.h
init.o: ../../../../winix/winixd/db/dbconn.h
init.o: ../../../../winix/winixd/db/dbtextstream.h
init.o: ../../../../winix/winixd/core/textstream.h
init.o: ../../../../winix/winixd/core/misc.h
init.o: ../../../../winix/winixd/core/item.h
init.o: ../../../../winix/winixd/core/requesttypes.h
init.o: ../../../../pikotools/textstream/textstream.h
init.o: ../../../../pikotools/membuffer/membuffer.h
init.o: ../../../../pikotools/textstream/types.h
init.o: ../../../../pikotools/utf8/utf8.h
init.o: ../../../../winix/winixd/core/winix_const.h
init.o: ../../../../pikotools/convert/convert.h
init.o: ../../../../pikotools/convert/inttostr.h
init.o: ../../../../pikotools/convert/patternreplacer.h
init.o: ../../../../pikotools/convert/strtoint.h
init.o: ../../../../pikotools/convert/text.h
init.o: ../../../../winix/winixd/core/winixbase.h
init.o: ../../../../winix/winixd/core/config.h
init.o: ../../../../pikotools/space/spaceparser.h
init.o: ../../../../pikotools/space/space.h
init.o: ../../../../winix/winixd/core/log.h
init.o: ../../../../winix/winixd/core/logmanipulators.h
init.o: ../../../../pikotools/log/log.h ../../../../pikotools/log/filelog.h
init.o: ../../../../winix/winixd/core/log.h
init.o: ../../../../winix/winixd/core/synchro.h
init.o: ../../../../winix/winixd/core/filelog.h
init.o: ../../../../winix/winixd/core/lock.h
init.o: ../../../../winix/winixd/core/synchro.h
init.o: ../../../../winix/winixd/core/error.h
init.o: ../../../../winix/winixd/db/dbitemquery.h
init.o: ../../../../winix/winixd/db/dbitemcolumns.h
init.o: ../../../../winix/winixd/core/user.h
init.o: ../../../../winix/winixd/core/group.h
init.o: ../../../../winix/winixd/core/dircontainer.h
init.o: ../../../../winix/winixd/core/winixbase.h
init.o: ../../../../winix/winixd/core/ugcontainer.h
init.o: ../../../../winix/winixd/core/request.h
init.o: ../../../../winix/winixd/core/error.h
init.o: ../../../../winix/winixd/core/config.h
init.o: ../../../../winix/winixd/core/textstream.h
init.o: ../../../../winix/winixd/templates/htmltextstream.h
init.o: ../../../../pikotools/space/spacetojson.h
init.o: ../../../../ezc/src/outstreams.h
init.o: ../../../../winix/winixd/core/system.h
init.o: ../../../../winix/winixd/core/job.h
init.o: ../../../../winix/winixd/core/basethread.h
init.o: ../../../../winix/winixd/core/winixmodel.h
init.o: ../../../../winix/winixd/core/plugin.h
init.o: ../../../../winix/winixd/core/pluginmsg.h
init.o: ../../../../winix/winixd/core/plugindata.h
init.o: ../../../../morm/src/morm.h ../../../../morm/src/morm_types.h
init.o: ../../../../morm/src/model.h ../../../../morm/src/modelconnector.h
init.o: ../../../../morm/src/clearer.h ../../../../morm/src/dbconnector.h
init.o: ../../../../morm/src/queryresult.h
init.o: ../../../../morm/src/flatconnector.h
init.o: ../../../../morm/src/dbexpression.h
init.o: ../../../../morm/src/baseexpression.h
init.o: ../../../../morm/src/flatexpression.h
init.o: ../../../../morm/src/modeldata.h ../../../../morm/src/finder.h
init.o: ../../../../morm/src/cursor.h ../../../../morm/src/jsonexpression.h
init.o: ../../../../morm/src/postgresqlexpression.h
init.o: ../../../../morm/src/dochtmlexpression.h
init.o: ../../../../morm/src/jsonconnector.h
init.o: ../../../../morm/src/postgresqlconnector.h
init.o: ../../../../morm/src/postgresqlqueryresult.h
init.o: ../../../../morm/src/dochtmlconnector.h
init.o: ../../../../winix/winixd/core/dirs.h
init.o: ../../../../winix/winixd/core/dircontainer.h
init.o: ../../../../winix/winixd/core/request.h
init.o: ../../../../winix/winixd/core/mounts.h
init.o: ../../../../winix/winixd/core/mount.h
init.o: ../../../../winix/winixd/core/mountparser.h
init.o: ../../../../winix/winixd/core/crypt.h
init.o: ../../../../winix/winixd/core/run.h
init.o: ../../../../winix/winixd/core/user.h
init.o: ../../../../winix/winixd/core/users.h
init.o: ../../../../winix/winixd/core/ugcontainer.h
init.o: ../../../../winix/winixd/core/lastcontainer.h
init.o: ../../../../winix/winixd/core/cur.h
init.o: ../../../../winix/winixd/core/session.h
init.o: ../../../../winix/winixd/core/rebus.h
init.o: ../../../../winix/winixd/core/ipban.h
init.o: ../../../../winix/winixd/core/groups.h
init.o: ../../../../winix/winixd/core/group.h
init.o: ../../../../winix/winixd/core/loadavg.h
init.o: ../../../../winix/winixd/core/image.h
init.o: ../../../../winix/winixd/core/threadmanager.h
init.o: ../../../../winix/winixd/notify/notify.h
init.o: ../../../../winix/winixd/notify/notifypool.h
init.o: ../../../../winix/winixd/templates/locale.h
init.o: ../../../../pikotools/convert/patternreplacer.h
init.o: ../../../../winix/winixd/templates/patterns.h
init.o: ../../../../winix/winixd/templates/locale.h
init.o: ../../../../winix/winixd/templates/localefilter.h
init.o: ../../../../ezc/src/ezc.h ../../../../ezc/src/generator.h
init.o: ../../../../ezc/src/blocks.h ../../../../ezc/src/cache.h
init.o: ../../../../ezc/src/functions.h ../../../../ezc/src/funinfo.h
init.o: ../../../../ezc/src/objects.h ../../../../ezc/src/pattern.h
init.o: ../../../../ezc/src/expressionparser.h
init.o: ../../../../ezc/src/patternparser.h
init.o: ../../../../winix/winixd/notify/notifythread.h
init.o: ../../../../winix/winixd/core/basethread.h
init.o: ../../../../winix/winixd/notify/templatesnotify.h
init.o: ../../../../winix/winixd/core/users.h
init.o: ../../../../winix/winixd/core/winixmodel.h
init.o: ../../../../winix/winixd/core/timezones.h
init.o: ../../../../winix/winixd/core/timezone.h
init.o: ../../../../winix/winixd/core/winixrequest.h
init.o: ../../../../winix/winixd/core/winixsystem.h
init.o: ../../../../winix/winixd/core/cur.h
init.o: ../../../../winix/winixd/core/sessionmanager.h
init.o: ../../../../winix/winixd/core/sessioncontainer.h
init.o: ../../../../winix/winixd/core/ipbancontainer.h
init.o: ../../../../winix/winixd/core/system.h
init.o: ../../../../winix/winixd/core/sessionidmanager.h
init.o: ../../../../tito/src/base64.h ../../../../tito/src/aes.h
init.o: ../../../../winix/winixd/core/slog.h
init.o: ../../../../winix/winixd/functions/functions.h
init.o: ../../../../winix/winixd/functions/functionbase.h
init.o: ../../../../winix/winixd/functions/functionparser.h
init.o: ../../../../winix/winixd/functions/account.h
init.o: ../../../../winix/winixd/functions/adduser.h
init.o: ../../../../winix/winixd/functions/cat.h
init.o: ../../../../winix/winixd/functions/chmod.h
init.o: ../../../../winix/winixd/functions/privchanger.h
init.o: ../../../../winix/winixd/functions/chown.h
init.o: ../../../../winix/winixd/functions/ckeditor.h
init.o: ../../../../winix/winixd/functions/cp.h
init.o: ../../../../winix/winixd/functions/default.h
init.o: ../../../../winix/winixd/functions/download.h
init.o: ../../../../winix/winixd/functions/emacs.h
init.o: ../../../../winix/winixd/functions/env.h
init.o: ../../../../winix/winixd/functions/imgcrop.h
init.o: ../../../../winix/winixd/functions/last.h
init.o: ../../../../winix/winixd/functions/login.h
init.o: ../../../../winix/winixd/functions/logout.h
init.o: ../../../../winix/winixd/functions/ln.h
init.o: ../../../../winix/winixd/functions/ls.h
init.o: ../../../../winix/winixd/functions/man.h
init.o: ../../../../winix/winixd/functions/meta.h
init.o: ../../../../winix/winixd/functions/mkdir.h
init.o: ../../../../winix/winixd/functions/mv.h
init.o: ../../../../winix/winixd/functions/nicedit.h
init.o: ../../../../winix/winixd/functions/node.h
init.o: ../../../../winix/winixd/functions/passwd.h
init.o: ../../../../winix/winixd/functions/priv.h
init.o: ../../../../winix/winixd/functions/pw.h
init.o: ../../../../winix/winixd/functions/reload.h
init.o: ../../../../winix/winixd/functions/rm.h
init.o: ../../../../winix/winixd/functions/rmuser.h
init.o: ../../../../winix/winixd/functions/sort.h
init.o: ../../../../winix/winixd/functions/specialdefault.h
init.o: ../../../../winix/winixd/functions/stat.h
init.o: ../../../../winix/winixd/functions/subject.h
init.o: ../../../../winix/winixd/functions/template.h
init.o: ../../../../winix/winixd/functions/tinymce.h
init.o: ../../../../winix/winixd/functions/uname.h
init.o: ../../../../winix/winixd/functions/upload.h
init.o: ../../../../winix/winixd/functions/uptime.h
init.o: ../../../../winix/winixd/functions/who.h
init.o: ../../../../winix/winixd/functions/vim.h
init.o: ../../../../winix/winixd/core/htmlfilter.h
seo.o: seo.h ../../../../winix/winixd/functions/functionbase.h
seo.o: ../../../../winix/winixd/core/item.h
seo.o: ../../../../pikotools/space/space.h
seo.o: ../../../../pikotools/textstream/types.h
seo.o: ../../../../pikotools/date/date.h
seo.o: ../../../../pikotools/convert/inttostr.h
seo.o: ../../../../winix/winixd/db/db.h ../../../../winix/winixd/db/dbbase.h
seo.o: ../../../../winix/winixd/db/dbconn.h
seo.o: ../../../../winix/winixd/db/dbtextstream.h
seo.o: ../../../../winix/winixd/core/textstream.h
seo.o: ../../../../winix/winixd/core/misc.h
seo.o: ../../../../winix/winixd/core/item.h
seo.o: ../../../../winix/winixd/core/requesttypes.h
seo.o: ../../../../pikotools/textstream/textstream.h
seo.o: ../../../../pikotools/membuffer/membuffer.h
seo.o: ../../../../pikotools/textstream/types.h
seo.o: ../../../../pikotools/utf8/utf8.h
seo.o: ../../../../winix/winixd/core/winix_const.h
seo.o: ../../../../pikotools/convert/convert.h
seo.o: ../../../../pikotools/convert/inttostr.h
seo.o: ../../../../pikotools/convert/patternreplacer.h
seo.o: ../../../../pikotools/convert/strtoint.h
seo.o: ../../../../pikotools/convert/text.h
seo.o: ../../../../winix/winixd/core/winixbase.h
seo.o: ../../../../winix/winixd/core/config.h
seo.o: ../../../../pikotools/space/spaceparser.h
seo.o: ../../../../pikotools/space/space.h
seo.o: ../../../../winix/winixd/core/log.h
seo.o: ../../../../winix/winixd/core/logmanipulators.h
seo.o: ../../../../pikotools/log/log.h ../../../../pikotools/log/filelog.h
seo.o: ../../../../winix/winixd/core/log.h
seo.o: ../../../../winix/winixd/core/synchro.h
seo.o: ../../../../winix/winixd/core/filelog.h
seo.o: ../../../../winix/winixd/core/lock.h
seo.o: ../../../../winix/winixd/core/synchro.h
seo.o: ../../../../winix/winixd/core/error.h
seo.o: ../../../../winix/winixd/db/dbitemquery.h
seo.o: ../../../../winix/winixd/db/dbitemcolumns.h
seo.o: ../../../../winix/winixd/core/user.h
seo.o: ../../../../winix/winixd/core/group.h
seo.o: ../../../../winix/winixd/core/dircontainer.h
seo.o: ../../../../winix/winixd/core/winixbase.h
seo.o: ../../../../winix/winixd/core/ugcontainer.h
seo.o: ../../../../winix/winixd/core/request.h
seo.o: ../../../../winix/winixd/core/error.h
seo.o: ../../../../winix/winixd/core/config.h
seo.o: ../../../../winix/winixd/core/textstream.h
seo.o: ../../../../winix/winixd/templates/htmltextstream.h
seo.o: ../../../../pikotools/space/spacetojson.h
seo.o: ../../../../ezc/src/outstreams.h
seo.o: ../../../../winix/winixd/core/system.h
seo.o: ../../../../winix/winixd/core/job.h
seo.o: ../../../../winix/winixd/core/basethread.h
seo.o: ../../../../winix/winixd/core/winixmodel.h
seo.o: ../../../../winix/winixd/core/plugin.h
seo.o: ../../../../winix/winixd/core/pluginmsg.h
seo.o: ../../../../winix/winixd/core/plugindata.h ../../../../morm/src/morm.h
seo.o: ../../../../morm/src/morm_types.h ../../../../morm/src/model.h
seo.o: ../../../../morm/src/modelconnector.h ../../../../morm/src/clearer.h
seo.o: ../../../../morm/src/dbconnector.h ../../../../morm/src/queryresult.h
seo.o: ../../../../morm/src/flatconnector.h
seo.o: ../../../../morm/src/dbexpression.h
seo.o: ../../../../morm/src/baseexpression.h
seo.o: ../../../../morm/src/flatexpression.h ../../../../morm/src/modeldata.h
seo.o: ../../../../morm/src/finder.h ../../../../morm/src/cursor.h
seo.o: ../../../../morm/src/jsonexpression.h
seo.o: ../../../../morm/src/postgresqlexpression.h
seo.o: ../../../../morm/src/dochtmlexpression.h
seo.o: ../../../../morm/src/jsonconnector.h
seo.o: ../../../../morm/src/postgresqlconnector.h
seo.o: ../../../../morm/src/postgresqlqueryresult.h
seo.o: ../../../../morm/src/dochtmlconnector.h
seo.o: ../../../../winix/winixd/core/dirs.h
seo.o: ../../../../winix/winixd/core/dircontainer.h
seo.o: ../../../../winix/winixd/core/request.h
seo.o: ../../../../winix/winixd/core/mounts.h
seo.o: ../../../../winix/winixd/core/mount.h
seo.o: ../../../../winix/winixd/core/mountparser.h
seo.o: ../../../../winix/winixd/core/crypt.h
seo.o: ../../../../winix/winixd/core/run.h
seo.o: ../../../../winix/winixd/core/user.h
seo.o: ../../../../winix/winixd/core/users.h
seo.o: ../../../../winix/winixd/core/ugcontainer.h
seo.o: ../../../../winix/winixd/core/lastcontainer.h
seo.o: ../../../../winix/winixd/core/cur.h
seo.o: ../../../../winix/winixd/core/session.h
seo.o: ../../../../winix/winixd/core/rebus.h
seo.o: ../../../../winix/winixd/core/ipban.h
seo.o: ../../../../winix/winixd/core/groups.h
seo.o: ../../../../winix/winixd/core/group.h
seo.o: ../../../../winix/winixd/core/loadavg.h
seo.o: ../../../../winix/winixd/core/image.h
seo.o: ../../../../winix/winixd/core/threadmanager.h
seo.o: ../../../../winix/winixd/notify/notify.h
seo.o: ../../../../winix/winixd/notify/notifypool.h
seo.o: ../../../../winix/winixd/templates/locale.h
seo.o: ../../../../pikotools/convert/patternreplacer.h
seo.o: ../../../../winix/winixd/templates/patterns.h
seo.o: ../../../../winix/winixd/templates/locale.h
seo.o: ../../../../winix/winixd/templates/localefilter.h
seo.o: ../../../../ezc/src/ezc.h ../../../../ezc/src/generator.h
seo.o: ../../../../ezc/src/blocks.h ../../../../ezc/src/cache.h
seo.o: ../../../../ezc/src/functions.h ../../../../ezc/src/funinfo.h
seo.o: ../../../../ezc/src/objects.h ../../../../ezc/src/pattern.h
seo.o: ../../../../ezc/src/expressionparser.h
seo.o: ../../../../ezc/src/patternparser.h
seo.o: ../../../../winix/winixd/notify/notifythread.h
seo.o: ../../../../winix/winixd/core/basethread.h
seo.o: ../../../../winix/winixd/notify/templatesnotify.h
seo.o: ../../../../winix/winixd/core/users.h
seo.o: ../../../../winix/winixd/core/winixmodel.h
seo.o: ../../../../winix/winixd/core/timezones.h
seo.o: ../../../../winix/winixd/core/timezone.h
seo.o: ../../../../winix/winixd/core/winixrequest.h
seo.o: ../../../../winix/winixd/core/winixsystem.h
seo.o: ../../../../winix/winixd/core/cur.h
seo.o: ../../../../winix/winixd/core/sessionmanager.h
seo.o: ../../../../winix/winixd/core/sessioncontainer.h
seo.o: ../../../../winix/winixd/core/ipbancontainer.h
seo.o: ../../../../winix/winixd/core/system.h
seo.o: ../../../../winix/winixd/core/sessionidmanager.h
seo.o: ../../../../tito/src/base64.h ../../../../tito/src/aes.h
seo.o: ../../../../winix/winixd/core/slog.h
seo.o: ../../../../winix/winixd/functions/functions.h
seo.o: ../../../../winix/winixd/functions/functionbase.h
seo.o: ../../../../winix/winixd/functions/functionparser.h
seo.o: ../../../../winix/winixd/functions/account.h
seo.o: ../../../../winix/winixd/functions/adduser.h
seo.o: ../../../../winix/winixd/functions/cat.h
seo.o: ../../../../winix/winixd/functions/chmod.h
seo.o: ../../../../winix/winixd/functions/privchanger.h
seo.o: ../../../../winix/winixd/functions/chown.h
seo.o: ../../../../winix/winixd/functions/ckeditor.h
seo.o: ../../../../winix/winixd/functions/cp.h
seo.o: ../../../../winix/winixd/functions/default.h
seo.o: ../../../../winix/winixd/functions/download.h
seo.o: ../../../../winix/winixd/functions/emacs.h
seo.o: ../../../../winix/winixd/functions/env.h
seo.o: ../../../../winix/winixd/functions/imgcrop.h
seo.o: ../../../../winix/winixd/functions/last.h
seo.o: ../../../../winix/winixd/functions/login.h
seo.o: ../../../../winix/winixd/functions/logout.h
seo.o: ../../../../winix/winixd/functions/ln.h
seo.o: ../../../../winix/winixd/functions/ls.h
seo.o: ../../../../winix/winixd/functions/man.h
seo.o: ../../../../winix/winixd/functions/meta.h
seo.o: ../../../../winix/winixd/functions/mkdir.h
seo.o: ../../../../winix/winixd/functions/mv.h
seo.o: ../../../../winix/winixd/functions/nicedit.h
seo.o: ../../../../winix/winixd/functions/node.h
seo.o: ../../../../winix/winixd/functions/passwd.h
seo.o: ../../../../winix/winixd/functions/priv.h
seo.o: ../../../../winix/winixd/functions/pw.h
seo.o: ../../../../winix/winixd/functions/reload.h
seo.o: ../../../../winix/winixd/functions/rm.h
seo.o: ../../../../winix/winixd/functions/rmuser.h
seo.o: ../../../../winix/winixd/functions/sort.h
seo.o: ../../../../winix/winixd/functions/specialdefault.h
seo.o: ../../../../winix/winixd/functions/stat.h
seo.o: ../../../../winix/winixd/functions/subject.h
seo.o: ../../../../winix/winixd/functions/template.h
seo.o: ../../../../winix/winixd/functions/tinymce.h
seo.o: ../../../../winix/winixd/functions/uname.h
seo.o: ../../../../winix/winixd/functions/upload.h
seo.o: ../../../../winix/winixd/functions/uptime.h
seo.o: ../../../../winix/winixd/functions/who.h
seo.o: ../../../../winix/winixd/functions/vim.h
seo.o: ../../../../winix/winixd/core/htmlfilter.h

@ -0,0 +1,76 @@
/*
* This file is a part of Winix
* and is distributed under the 2-Clause BSD licence.
* Author: Tomasz Sowa <t.sowa@ttmath.org>
*/
/*
* Copyright (c) 2019, Tomasz Sowa
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*
*/
#include "seo.h"
#include "functions/functions.h"
namespace Winix
{
extern "C" void Init(PluginInfo &);
namespace Seo
{
const wchar_t plugin_name[] = L"seo";
Seo fun_seo;
void AddFunctions(PluginInfo & info)
{
info.functions->Add(fun_seo);
}
} // namespace Ticket
void Init(PluginInfo & info)
{
using namespace Seo;
info.plugin->Assign(WINIX_CREATE_FUNCTIONS, AddFunctions);
info.p1 = (void*)(plugin_name);
}
} // namespace Winix

@ -0,0 +1,94 @@
/*
* This file is a part of Winix
* and is distributed under the 2-Clause BSD licence.
* Author: Tomasz Sowa <t.sowa@ttmath.org>
*/
/*
* Copyright (c) 2019, Tomasz Sowa
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*
*/
#include "seo.h"
#include "functions/functions.h"
namespace Winix
{
namespace Seo
{
Seo::Seo()
{
fun.url = L"seo";
}
bool Seo::HasAccess()
{
if( cur->session->puser && cur->session->puser->super_user )
return true;
return system->HasWriteAccess(*cur->request->last_item);
}
void Seo::MakeGet()
{
}
void Seo::MakePost()
{
Item & item = *cur->request->last_item;
const std::wstring & subject = cur->request->PostVar(L"subject");
const std::wstring & description = cur->request->PostVar(L"description");
const std::wstring & keywords = cur->request->PostVar(L"keywords");
item.subject = subject;
PT::Space & seo = item.meta.FindAddSpace(L"seo");
seo.Add(L"description", description);
seo.Add(L"keywords", keywords);
db->EditSubjectById(item, item.id);
db->EditMetaById(item.meta, item.id);
}
} // namespace
} // namespace Winix

@ -0,0 +1,70 @@
/*
* This file is a part of Winix
* and is distributed under the 2-Clause BSD licence.
* Author: Tomasz Sowa <t.sowa@ttmath.org>
*/
/*
* Copyright (c) 2019, Tomasz Sowa
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*
*/
#ifndef headerfile_winix_plugins_seo_seo
#define headerfile_winix_plugins_seo_seo
#include "functions/functionbase.h"
namespace Winix
{
namespace Seo
{
class Seo : public FunctionBase
{
public:
Seo();
bool HasAccess();
void MakePost();
void MakeGet();
private:
};
} // namespace
} // namespace Winix
#endif
Loading…
Cancel
Save