Re: [xwiki-users] Adding css style to page

2016-08-20 Thread Tim Dudgeon

Thanks. Omitting the  tags solved it.

Thanks for your help with this.

Tim


On 20/08/2016 17:26, Vincent Massol wrote:
</pre><blockquote style="border-left: #EE solid 0.2em; margin: 0em; padding-left: 0.85em"><blockquote style="border-left: #EE solid 0.2em; margin: 0em; padding-left: 0.85em"><pre style="margin: 0em;">
On 20 Aug 2016, at 16:20, Tim Dudgeon <tdudgeon...@gmail.com> wrote:

Vincent,

thanks. The SkinExtensions did the trick.

I did find one strange thing in that the first style definition was ignored. I 
needed to put some dummy style at the start to get the one I needed to work.

<style>
p.random_as_first_line_is_ignored {} # never gets into the html

div.example { # this one does
padding-top: 8px;
padding-bottom: 5px;
font-family: monospace;
color: green;
}


Note that you shouldn’t put  inside the SSX.

To verify what happens, use the view source feature of your browser and locate the 
line in the <head> that’s like:

<link rel="stylesheet" type="text/css" href=“<URL to your SSX wiki page>”/>

When open the <URL to your SSX wiki page> in your browser and you’ll see what 
gets executed.

Thanks
-Vincent

</pre><blockquote style="border-left: #EE solid 0.2em; margin: 0em; padding-left: 0.85em"><pre style="margin: 0em;">
This is with version 7.4.2.


Tim






On 20/08/2016 13:56, Vincent Massol wrote:
</pre><blockquote style="border-left: #EE solid 0.2em; margin: 0em; padding-left: 0.85em"><pre style="margin: 0em;">
Hi Tim,

</pre><blockquote style="border-left: #EE solid 0.2em; margin: 0em; padding-left: 0.85em"><pre style="margin: 0em;">
On 20 Aug 2016, at 14:32, Tim Dudgeon <tdudgeon...@gmail.com> wrote:

Hi Folks,

I'm struggling with something I thought should be quite simple.
I want to style a series of elements in a page (box macro) so want to
just define a css style for this just for this one page.
I was trying to set styles using html content like this:

{{html}}<style>
h1 {color:red;}
p {color:blue;}

{{/html}}

but the style definition is not getting included (though in other cases
like this {{html}}bold text{{/html}} its working as expected).

What am I doing wrong here?

BTW it’s not a good web practice to put CSS inside the HTML body. I suggest 
using http://platform.xwiki.org/xwiki/bin/view/DevGuide/SkinExtensionsTutorial

Can you try with this and see if it helps?

Thanks
-Vincent

PS1: You can use your browser dev tool to see what CSS you need to write to 
style what you want
PS2: The box macro supports defining some css class that can be added, see 
http://extensions.xwiki.org/xwiki/bin/view/Extension/Box+Macro#HParametersdefinition


Thanks
Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Adding css style to page

2016-08-20 Thread Tim Dudgeon

Vincent,

thanks. The SkinExtensions did the trick.

I did find one strange thing in that the first style definition was 
ignored. I needed to put some dummy style at the start to get the one I 
needed to work.



p.random_as_first_line_is_ignored {} # never gets into the html

div.example { # this one does
padding-top: 8px;
padding-bottom: 5px;
font-family: monospace;
color: green;
}


This is with version 7.4.2.


Tim






On 20/08/2016 13:56, Vincent Massol wrote:

Hi Tim,


On 20 Aug 2016, at 14:32, Tim Dudgeon <tdudgeon...@gmail.com> wrote:

Hi Folks,

I'm struggling with something I thought should be quite simple.
I want to style a series of elements in a page (box macro) so want to
just define a css style for this just for this one page.
I was trying to set styles using html content like this:

{{html}}
h1 {color:red;}
p {color:blue;}

{{/html}}

but the style definition is not getting included (though in other cases
like this {{html}}bold text{{/html}} its working as expected).

What am I doing wrong here?

BTW it’s not a good web practice to put CSS inside the HTML body. I suggest 
using http://platform.xwiki.org/xwiki/bin/view/DevGuide/SkinExtensionsTutorial

Can you try with this and see if it helps?

Thanks
-Vincent

PS1: You can use your browser dev tool to see what CSS you need to write to 
style what you want
PS2: The box macro supports defining some css class that can be added, see 
http://extensions.xwiki.org/xwiki/bin/view/Extension/Box+Macro#HParametersdefinition


Thanks
Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] Adding css style to page

2016-08-20 Thread Tim Dudgeon

Hi Folks,

I'm struggling with something I thought should be quite simple.
I want to style a series of elements in a page (box macro) so want to
just define a css style for this just for this one page.
I was trying to set styles using html content like this:

{{html}}
h1 {color:red;}
p {color:blue;}

{{/html}}

but the style definition is not getting included (though in other cases
like this {{html}}bold text{{/html}} its working as expected).

What am I doing wrong here?

Thanks
Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] Display line numbers in code macro?

2016-06-10 Thread Tim Dudgeon

Is it possible to display line numbers using the code macro extension?
http://extensions.xwiki.org/xwiki/bin/view/Extension/Code+Macro

Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Can't get Export/Import to work

2016-04-29 Thread Tim Dudgeon

On 25/04/2016 08:04, Vincent Massol wrote:


I’ve documented this at 
http://platform.xwiki.org/xwiki/bin/view/AdminGuide/NginX#HRequestEntityTooLarge

BTW, would be great if you could validate the nginx configuration there. It was 
entered by a contributor and not by any member of the xwiki dev team (we don’t 
use nginx) so we don’t know if the config is good or not, and thus it can be 
promoted as a good configuration to follow. Do you think you could do that?


I can't really validate that config as a whole as it serves its own 
purpose (and I'm no nginx expert).
But taking a quick look the basic proxy configuration (the last location 
section) looks OK to me.
The major comment I would have is that this is not a proxy setup for 
using TLS, which would normally be one of the main reasons for using a 
reverse proxy.
I'd be happy to send you my config (that does handle TLS) though I'd 
need to "sanitise" it a bit first.


Tim


___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Can't get Export/Import to work

2016-04-23 Thread Tim Dudgeon

On 22/04/2016 16:07, Clemens Klein-Robbenhaar wrote:

This blog post:


http://cnedelcu.blogspot.de/2013/09/nginx-error-413-request-entity-too-large.html

tells me nginx does not allow request bodies larger than 1mb by default

if you use nginx you might want to update this configuration variable:

   http://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size

hth
clemens



Yes, confirmed. That was indeed the problem. Raising the limit solved 
the problem.


Thanks
Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Can't get Export/Import to work

2016-04-22 Thread Tim Dudgeon

On 22/04/2016 16:07, Clemens Klein-Robbenhaar wrote:

This blog post:


http://cnedelcu.blogspot.de/2013/09/nginx-error-413-request-entity-too-large.html

tells me nginx does not allow request bodies larger than 1mb by default

if you use nginx you might want to update this configuration variable:

   http://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size

hth
clemens


Ah, that could well be it. This is running behind an nginx reverse 
proxy. I'll give it a try.


Thanks
Tim


___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Can't get Export/Import to work

2016-04-22 Thread Tim Dudgeon

In the range of 2-3 MB

Tim

On 22/04/2016 13:21, Thomas Mortagne wrote:

What size is this XAR ?

On Fri, Apr 22, 2016 at 2:01 PM, Tim Dudgeon
<tdudg...@informaticsmatters.com> wrote:

On 22/04/2016 12:19, Thomas Mortagne wrote:


Do you have anything related in the log ?



Not in the Tomcat logs, but I found something in the javascript console:

Failed to load resource: the server responded with a status of 413 (Request
Entity Too Large)

with some link to
https:///xwiki/bin/upload/XWiki/XWikiPreferences


Tim


___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users







___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Can't get Export/Import to work

2016-04-22 Thread Tim Dudgeon

On 22/04/2016 12:19, Thomas Mortagne wrote:

Do you have anything related in the log ?


Not in the Tomcat logs, but I found something in the javascript console:

Failed to load resource: the server responded with a status of 413 
(Request Entity Too Large)


with some link to
https:///xwiki/bin/upload/XWiki/XWikiPreferences

Tim


___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] Can't get Export/Import to work

2016-04-22 Thread Tim Dudgeon
Using a simple XWiki 7.4.2 system I'm having problems getting Export and 
then Import to work. I'm want to export the entire contents of one Wiki 
and import it into another one.

I think I'm following the instructions here correctly:
http://platform.xwiki.org/xwiki/bin/view/AdminGuide/ImportExport
The Export seem to go OK and generates a xar file.
But when I try to Import that into a different 7.4.2 wiki (or even the 
one it was exported from) I get told that "No package is available for 
import".

Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] Advice on building simple app

2016-04-18 Thread Tim Dudgeon

Hi all,

I'm wanting to create a simple XWiki "app" and being new to this wanted 
to get some advice before starting.
What I want is probably not too far removed from the FAQ app, so it may 
well look a bit like this, but I wanted to get some pointers before 
heading off in the wrong direction.


The app is essentially a directory of "things" where each "thing" will 
be its own wiki page, and there will be a master page that lists them 
all and allow pagination, filtering etc. (livetable etc.)
The "things" will have a small number of "fields", not too different 
from the FAQ app. But where it may differ is that the page for each 
"thing" should also allow free form editing of the wiki page so that 
arbitrary additional info can be added (even including scripts etc.) 
This arbitrary extra info will just be part or the page, not part of the 
directory.
The page for each "thing" will therefore be a combination of structured 
info (the fields) appearing at the top of the page in a consistent 
manner across all pages), and non-structured info appearing below this.


All advice greatly appreciated.

Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] Wiki setup as authenticated user

2016-03-19 Thread Tim Dudgeon
I'm trying to set up a XWiki site using container (tomcat) 
authentication. The authentication pat is working fine, but I'm having 
any issue when initialising the site for the first time.
Normally (without authentication) xwiki spots that the wiki doesn't 
exist, and creates it (presumably using some magical user it creates).
But when I have authentication the initial wiki creation step does not 
happen and you go straight to a "page can't be found" message, even if 
the authenticated use is part of the XWikiAdminGroup.


Is there any solution to this, or must the wiki be created before any 
authentication is put in place?


Thanks
Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Container authentication

2015-08-26 Thread Tim Dudgeon

So its not working for me.

I've made sure the external user has the XWiki.XWikiAllGroup role and 
its still not working. The user does not get the necessary rights and I 
get the Error. You are not allowed to view this document or perform 
this action error message.

Also, that user is not added to the XWiki users.

Are there any example sof how to get this working?

Tim



On 26/08/2015 02:51, Thomas Mortagne wrote:

On Tue, Aug 25, 2015 at 5:04 PM, Tim Dudgeon
tdudg...@informaticsmatters.com wrote:

So it looks like the AppServerTrustedAuthServiceImpl class is calling
createUser():
https://github.com/xwiki/xwiki-platform/blob/dd5152e8ff39e6358c20becb4c9925628cf08ea4/xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/user/impl/xwiki/AppServerTrustedAuthServiceImpl.java

But that should mean that my externally authenticated user should be being
added and should get the XWiki.XWikiAllGroup.

But that doesn't seem to be happening in my case as I'm being although I'm
authenticated I'm denied access.


It's easy to check in the administration who is part of XWikiAllGroup.



Have I misunderstood the situation?

Tim




On 24/08/2015 10:15, Thomas Mortagne wrote:


Note that an authenticator is supposed to use
com.xpn.xwiki.XWiki#createUser API which automatically add the user in
the minimum groups.

On Mon, Aug 24, 2015 at 4:11 PM, Thomas Mortagne
thomas.morta...@xwiki.com wrote:


The minimum group is XWiki.XWikiAllGroup.

On Mon, Aug 24, 2015 at 1:50 PM, Tim Dudgeon
tdudg...@informaticsmatters.com wrote:


On 24/08/2015 04:24, Thomas Mortagne wrote:



Sounds like your user is not added in the right group(s) (which mean
it does not have any right).




Quite likely. But what groups are needed?


Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users





--
Thomas Mortagne








___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users







___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Container authentication

2015-08-25 Thread Tim Dudgeon
So it looks like the AppServerTrustedAuthServiceImpl class is calling 
createUser():

https://github.com/xwiki/xwiki-platform/blob/dd5152e8ff39e6358c20becb4c9925628cf08ea4/xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/user/impl/xwiki/AppServerTrustedAuthServiceImpl.java

But that should mean that my externally authenticated user should be 
being added and should get the XWiki.XWikiAllGroup.


But that doesn't seem to be happening in my case as I'm being although 
I'm authenticated I'm denied access.


Have I misunderstood the situation?

Tim



On 24/08/2015 10:15, Thomas Mortagne wrote:

Note that an authenticator is supposed to use
com.xpn.xwiki.XWiki#createUser API which automatically add the user in
the minimum groups.

On Mon, Aug 24, 2015 at 4:11 PM, Thomas Mortagne
thomas.morta...@xwiki.com wrote:

The minimum group is XWiki.XWikiAllGroup.

On Mon, Aug 24, 2015 at 1:50 PM, Tim Dudgeon
tdudg...@informaticsmatters.com wrote:

On 24/08/2015 04:24, Thomas Mortagne wrote:


Sounds like your user is not added in the right group(s) (which mean
it does not have any right).



Quite likely. But what groups are needed?


Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users




--
Thomas Mortagne







___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Container authentication

2015-08-24 Thread Tim Dudgeon

On 24/08/2015 04:24, Thomas Mortagne wrote:

Sounds like your user is not added in the right group(s) (which mean
it does not have any right).


Quite likely. But what groups are needed?

Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Change Page Owner

2015-08-23 Thread Tim Dudgeon

Well, I suppose the scenario is like this.
Your company has 2 users, Jon and Sam.
Jon has just left the company and Sam is picking up all his work.
There needs to be a simple way to transfer Jon's rights to all 
documents and apps to Sam.
Its probably correct to leave Jon as a user, but just inactivate the 
account (e.g. the fact the Jon created and edited some docs is important 
information and should not be lost).
But there needs to be a simple way to enable Sam to do anything that Jon 
used to be able to do on all of those docs. e.g. not have to make a 
manual change on every document.

Maybe there's already a way to do this.

Tim


On 23/08/2015 18:40, vinc...@massol.net wrote:

Hi Tim,

On 23 Aug 2015 at 22:53:56, Tim Dudgeon 
(tdudg...@informaticsmatters.com(mailto:tdudg...@informaticsmatters.com)) wrote:


I'd certainly give that a +1. Seems like pretty necessary functionality.
Also, to be able to transfer ownership of all items belonging to a user
(useful when someone leaves your organisation and you need to transfer
their stuff to someone else).


Note that you can remove a user without having to transfer any ownership and 
you don’t need to be the creator of a page to be allowed to modify it or have 
permissions on it.

Also, even if someone leaves a company they’re still the creator of the pages 
they created (in reality, this can never be removed, they’ll always be the 
creator of that page, even if you try to hide it ;)).

Personally I don’t see this feature as a necessary one. I’m curious: why do you 
think it’s necessary? :)

Thanks
-Vincent


Tim

On 23/08/2015 13:39, vinc...@massol.net wrote:

Hi Hamster,

On 22 Aug 2015 at 09:17:37, Hamster 
(teun...@hotmail.com(mailto:teun...@hotmail.com)) wrote:


Just wondering...3 1/2 years ago it was not possible to change the owner of a
page in the UI.

Is this now possible (with XWiki 7.x) within the UI or do I still need to
use the script?


It’s still not possible to do it with the UI (you have to use a script). The 
reason it hasn’t changed is that nobody has asked for it :)

If you think such a UI feature is needed please create a jira issue for it, 
with some description as to where you’d see it located in the UI and how it 
would work.

Thanks
-Vincent

[snip]

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users




___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] Container authentication

2015-08-20 Thread Tim Dudgeon
I'm wanting to use container (tomcat) authentication with XWiki so that 
I can use a single sign on solution, using the instructions found here:

http://platform.xwiki.org/xwiki/bin/view/AdminGuide/Authentication#HContainerAuthentication

I managed to get something basic set up and the authentication is 
working (the container challenges me for username/password) but when the 
XWiki page displays it is completely unstyled (though I see my username 
in the content so the authentication is being picked up) and it displays 
an Error. You are not allowed to view this document or perform this 
action error message in the page.


So its looking like XWiki is not picking up (or generating) some 
resources it needs for that authenticated user (presumably because it 
did not go through the user registration process).

Or is it expected some specific role to be assigned to the user?

What's the trick to get this working correctly?

And on a related topic, is there a way to get XWiki to understand 
additional user credentials such as their real name e.g. from the 
authentication token or whatever?



Thanks
Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] Exporting a space

2013-09-20 Thread Tim Dudgeon
Would welcome some advice on how to export the contents of an entire 
space so that it can be imported into a different XWiki instance.

I looked at this:
http://platform.xwiki.org/xwiki/bin/view/Features/Exports
and reading between the lines thought that a URL like this should do the 
trick:

http://localhost:8080/xwiki/bin/export/Space/Page?format=xarpages=MySpace.%25name=MySpace
It does indeed generate a MySpace.xar file, but its contents are not 
what are desired. Just a single page called %.xml


I also noticed this extension:
http://extensions.xwiki.org/xwiki/bin/view/Extension/Multipage+Export+Application
Maybe that can do the trick.

Advice welcome. Surely this needs to be done all the time so must be 
easily solvable?


Tim

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users