Expand my Community achievements bar.

SOLVED

Error with API demo/PHP sample number 3

Avatar

Former Community Member

I'm trying to execute demo php samples and when I run demo/03_update_home_collection.php then I get the following error: Array ( [code] => BadRequestException[message] => Attempting to set a bogus version= )

What's that?

1 Accepted Solution

Avatar

Correct answer by
Employee

Hi,

Is the project that you set up a 1 top-level nav collection or 2 top-level nav collection? I am assuming that it is the latter. You can find out by going to the Project Settings rail > select the project > edit > go to App Navigation tab.

If so, please update the $collection_home_name variable (located in 20150810-DPS-Content Producer Service API-Examples/demo/demo_parameters.php) to either one of the following:

  • $collection_home_name = "topLevelTabletContent"; // for tablet collection
  • $collection_home_name = "topLevelPhoneContent"; // for phone collection

The demo will only target one of the top-level collections. You can also find this info in 20150810-DPS-Content Producer Service API-Examples/demo/README.md.

View solution in original post

3 Replies

Avatar

Correct answer by
Employee

Hi,

Is the project that you set up a 1 top-level nav collection or 2 top-level nav collection? I am assuming that it is the latter. You can find out by going to the Project Settings rail > select the project > edit > go to App Navigation tab.

If so, please update the $collection_home_name variable (located in 20150810-DPS-Content Producer Service API-Examples/demo/demo_parameters.php) to either one of the following:

  • $collection_home_name = "topLevelTabletContent"; // for tablet collection
  • $collection_home_name = "topLevelPhoneContent"; // for phone collection

The demo will only target one of the top-level collections. You can also find this info in 20150810-DPS-Content Producer Service API-Examples/demo/README.md.

Avatar

Former Community Member

mike-o thank you very very much. I felt ashamed for not seeing this in the readme. Everything worked fine now.

Avatar

Employee

No worries, please let us know if you encounter any further issues/questions.