Thx Tony
But the sad thing is, it didn't work.
Maybe I screwed something up somewhere else I'll post the full modified
code.
\define ShowButton()
Press this button and the tiddler will be created and opened so you can
view it.
<$button>Create Tiddler
<$action-setfield $tiddler={{$:/state/NewTiddlerForm!!name_temp}} text={{$:
/state/NewTiddlerForm!!text}} description={{$:/state/NewTiddlerForm!!
description}} tags={{$:/state/NewTiddlerForm!!tags}}/>
<$action-navigate $to={{$:/state/NewTiddlerForm!!name_temp}}/>
<$action-setfield $tiddler='$:/state/NewTiddlerForm' name_temp='' text=''
description='' tags=''/>
</$button>
<$button>Clear Form
<$action-setfield $tiddler='$:/state/NewTiddlerForm' name_temp='' text=''
description='' tags=''/>
</$button>
\end
\define ShowExist() @@color:red; ''This tiddler exists pick a different
name''@@
Here it goes wrong
\define filter() [title[{$:/state/NewTiddlerForm!!name_temp}]is[tiddler]]
Here is the rest of it
!!Step 1 - ''Give the tiddler a name''
---
<$edit-text class='tc-edit-texteditor' tiddler='$:/state/NewTiddlerForm'
field='name_temp' placeholder='Tiddler Name'/><br>
!!Step 2 - ''Fill in tiddler text''
---
You can use any WikiText here, see [[Wiki Formatting - text, tables, etc.]]
for some easy examples of text formatting.
You can resize the exiting field by clicking and dragging the lower right
corner.
<$edit-text class='tc-edit-texteditor' tiddler='$:/state/NewTiddlerForm'
field='text' placeholder='Tiddler Text'/><br>
!!Step 3 - ''Give the tiddler a description'' (optional)
---
This can be used as a short description or summary of what each tiddler is.
It can be useful in lists.
<$edit-text class='tc-edit-texteditor' tiddler='$:/state/NewTiddlerForm'
field='description' placeholder='Tiddler Description'/><br>
!!Step 4 - ''Add a tag or tags to the tiddler'' (optional)
---
Tags are used for the table of contents, so it may be advisable to add tags
to new tiddlers. For example, if you wanted to add a tiddler that would be
displayed under 'Tools' in the table of contents you would add the 'Tools'
tag to the tiddler.
<$select tiddler='$:/state/NewTiddlerForm' field='add_or_create_tag'>
<option value='existing'>Add existing tag</option>
<option value='create'>Add a new tag</option>
</$select>
<$reveal type=match state='$:/state/NewTiddlerForm!!add_or_create_tag'
text='create'>
New Tag Name: <$edit-text tiddler='$:/state/NewTiddlerForm' field='tag_temp'
placeholder='New Tag'/><$fieldmangler tiddler='$:/state/NewTiddlerForm'>
<$button>
<$action-sendmessage $message='tm-add-tag'
$param={{$:/state/NewTiddlerForm!!tag_temp}}/>
<$action-setfield $tiddler='$:/state/NewTiddlerForm' $field='tag_temp'
$value=''/>Add Tag
</$button>
</$fieldmangler><br>
</$reveal>
<$reveal type='match' state='$:/state/NewTiddlerForm!!add_or_create_tag'
text='existing'>
Tag to add: <$select tiddler='$:/state/NewTiddlerForm' field='tag_temp'>
<$list filter='[tags[]sort[title]]'>
<option><$view field='title'/></option>
</$list>
</$select>
<$fieldmangler tiddler='$:/state/NewTiddlerForm'>
<$button>
<$action-sendmessage $message='tm-add-tag'
$param={{$:/state/NewTiddlerForm!!tag_temp}}/>Add Tag
</$button>
</$fieldmangler>
<br>
</$reveal>
List of current tags:<br>
<$fieldmangler tiddler='$:/state/NewTiddlerForm'>
<$set name=tiddlerEditing value='$:/state/NewTiddlerForm'>
<$list filter='[[$:/state/NewTiddlerForm]tags[]]'><$view field='title'/>
<$button>Remove Tag<$action-sendmessage $message='tm-remove-tag'
$param=<<currentTiddler>>/></$button><br> </$list>
</$set>
</$fieldmangler>
!!Step 5 - ''Create the tiddler''
---
<$list filter=<<filter>> emptyMessage=<<ShowButton>>> <<ShowExist>> </$list>
As I said before only the parts to check for the titel I added
All the rest is done by far beter ppl than me.
--
You received this message because you are subscribed to the Google Groups
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/a59fcc92-cfd0-4d61-9047-105210c94825%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.