Instead of defining that macro on every page, could I define it in a single 
place and refer to it on each Tiddler that needs it? How would I do that?


On Sunday, January 13, 2019 at 2:11:34 PM UTC-5, S. S. wrote:
>
> Jeff,
>
> The macro instructions given before can be modified to this:
>
> \define external-document(file:{{!!file}} path:{{!!path}} page:{{!!pdf-
> page-number}})
> \rules except wikilink
> <$wikify name="location" text="$path$$file$#page=$page$">
> <a href=<<location>> target="_blank">$file$</a>
> </$wikify>
> \end
>
> Add another new field to your tiddler called: *pdf-page-number*
> Give it a value of the page number desired.
>
> Hope that helps.
>
> Regards.
>
> On Sunday, January 13, 2019 at 11:54:47 PM UTC+7, Jeff Wilson wrote:
>>
>> What would be really cool is to add a custom field to the TiddlyWiki 
>> called pdf-page-number, which I could then edit on every page that has a 
>> link to the PDF. Then the macro or whatever could use the value in that 
>> field to add the '#page=$pdf-page-number$' suffix to the URL.
>>
>> This would require that I understand several things:
>>
>>
>>    - How does one create a custom field and display it in the editor?
>>    - How does that change the macro below? Is it as simple as referring 
>>    to the field like a variable, which I believe is $variable-name$?
>>    - Where does the macro get written in TiddlyWiki, and how do I make 
>>    it available to each page?
>>
>>
>> On Saturday, January 12, 2019 at 11:15:25 PM UTC-5, TonyM wrote:
>>>
>>> A Promised example
>>>
>>> Concatenate to get a link
>>>
>>> \define doc-link(path name parameters)
>>> $path$$name$$parameters$
>>> \end
>>>  
>>> <a href=<<doc-link "http://gahp.net/wp-content/uploads/2017/09/"; 
>>> "sample.pdf" "#page=3">> >My PDF File</a>
>>>
>>> <a href=<<doc-link "http://gahp.net/wp-content/uploads/2017/09/"; "sample
>>> .pdf" "#page=5">> target=PDFTab >My PDF File</a>
>>>
>>> In this case we can embed a macro (with parameters) inside HTML.
>>>
>>> The second example is always going to use the same browser tab/window ( 
>>> a recent discovery of mine)
>>>
>>> Regards
>>> Tony
>>>
>>> On Sunday, January 13, 2019 at 2:23:06 PM UTC+11, TonyM wrote:
>>>>
>>>> Jeff,
>>>>
>>>> We do not mind critsisium, we are always trying to improve things, I 
>>>> expect the documentation to be easier to improve soon.
>>>>
>>>> There is however a reason why what you expected did not work, part of 
>>>> this is using more than one form of coding html, wikitext, macros, css and 
>>>> behind some macros javascript. One does not always embed in the other 
>>>> without further consideration. Show me an example elsewhere of this and we 
>>>> may harvest some ideas.
>>>>
>>>> When we want to embed one "Language" in another a common practice is to 
>>>> construct the code in a macro definition. I will try and locate an example 
>>>> when off my mobile.
>>>>
>>>> My point is tiddlywiki can stimulate our imagination so much we have 
>>>> ideas about how it can be, when there are complications that are not so 
>>>> obviouse, because we have multiple coding methods available at once, in an 
>>>> always up to date interlinked interactive platform.
>>>>
>>>> I empathise, and have thought the same way, but I am starting to see 
>>>> how tiddlywiki raises our expectations to exceed what it currently 
>>>> achives. 
>>>> Most often a work around exists, or the community starts to digest changes 
>>>> to come. The key is the community, conversations and change. Its not that 
>>>> tw is not mature, its that it continues to evolve even although in many 
>>>> respects it already surpasses the competition in capabilities (if not 
>>>> simplicity). 
>>>>
>>>> In my view Far too often today, simplicity is the result of the startup 
>>>> culture, which wants to profit from minimalist solutions, to fund the 
>>>> development of more comprehencive solutions by charging and taxing their 
>>>> very same clients. Unnesasary compexity is desirable but not at the cost 
>>>> of 
>>>> capability, unnessasariily simple things fragment what we need to use into 
>>>> too many parts.
>>>>
>>>> TiddlyWiki exists at a point of convergence of multiple technologies 
>>>> and thus is capable of great divergence as well. In this centre there are 
>>>> artifacts, but there is also code patterns and methods to address them.
>>>>
>>>> Regards
>>>> Tony
>>>>
>>>>

-- 
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/41b8cc4a-bc0a-44e8-bf5b-330875ba139e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to