File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -24,11 +24,11 @@ use CloudPlayDev\ConfluenceClient\Curl;
24
24
use CloudPlayDev\ConfluenceClient\Entity\ConfluencePage;
25
25
26
26
//Create and configure a curl web client
27
- $curl = new Curl('confluence_host_url','username','password');
27
+ $httpClient = new Curl('confluence_host_url','username','password');
28
28
// $curl = new CurlTokenAuth('confluence_host_url','NjU9OTXA4NDI2MRY5OkBznOUO8YjaUF7KoOruZRXhILJ9');
29
29
30
30
//Create the Confluence Client
31
- $client = new Client($curl );
31
+ $client = new Client($httpClient );
32
32
33
33
//Create a confluence page
34
34
$page = new ConfluencePage();
@@ -40,11 +40,17 @@ $page->setSpace('testSpaceKey')->setTitle('Test')->setContent('<p>test page</p>'
40
40
$client->createPage($page);
41
41
42
42
//Get the page we created
43
- $client->selectPageBy([
43
+ $createdPage = $ client->selectPageBy([
44
44
'spaceKey' => 'testSpaceKey',
45
45
'title' => 'Test'
46
46
]);
47
47
48
+ //Update page content
49
+ $createdPage->setContent('some new content');
50
+ $client->updatePage($createdPage);
51
+
52
+
53
+
48
54
```
49
55
50
56
You can’t perform that action at this time.
0 commit comments